diff --git a/src/mc_electron/T2Ie_disexc.h b/src/mc_electron/T2Ie_disexc.h index 492d672..05ef42e 100644 --- a/src/mc_electron/T2Ie_disexc.h +++ b/src/mc_electron/T2Ie_disexc.h @@ -31,7 +31,7 @@ inline InteractionOut T2Ie_DissExc::do_Interaction (Particle *interPart) { Particle TI = Particle_Builder::create_TI(loc_m, vTI_ms, -1, interPart->get_Id()); res.add_new_particle(TI); double E_eV = calc_E_eV_from_v_ms(Population->roll_v_ms(interPart->get_x_m()), me_eV); // should be computed properly using chances. - //Population->decrease_denisty(loc_m, E_eV); + Population->decrease_denisty(loc_m, E_eV); return res; } diff --git a/src/mc_electron/T2Ie_recombination.h b/src/mc_electron/T2Ie_recombination.h index e496d03..c4a159d 100644 --- a/src/mc_electron/T2Ie_recombination.h +++ b/src/mc_electron/T2Ie_recombination.h @@ -25,10 +25,10 @@ public: inline InteractionOut T2Ie_Recombination::do_Interaction (Particle *interPart) { InteractionOut res; res.set_delete_current(true); - /* + double E_eV = calc_E_eV_from_v_ms(Population->roll_v_ms(interPart->get_x_m()), me_eV); // should be computed properly using chances. Population->decrease_denisty(interPart->get_x_m(), E_eV); - */ + return res; } diff --git a/src/mc_electron/T3Ie_disexc.h b/src/mc_electron/T3Ie_disexc.h index f6260ce..e731841 100644 --- a/src/mc_electron/T3Ie_disexc.h +++ b/src/mc_electron/T3Ie_disexc.h @@ -30,7 +30,7 @@ inline InteractionOut T3Ie_DissExc::do_Interaction (Particle *interPart) { Particle TI = Particle_Builder::create_TI(loc_m, vTI_ms, -1, interPart->get_Id()); res.add_new_particle(TI); double E_eV = calc_E_eV_from_v_ms(Population->roll_v_ms(interPart->get_x_m()), me_eV); // should be computed properly using chances. - //Population->decrease_denisty(loc_m, E_eV); + Population->decrease_denisty(loc_m, E_eV); return res; } diff --git a/src/mc_electron/T3Ie_recombination.h b/src/mc_electron/T3Ie_recombination.h index 9308dcf..0a95cd0 100644 --- a/src/mc_electron/T3Ie_recombination.h +++ b/src/mc_electron/T3Ie_recombination.h @@ -24,10 +24,10 @@ public: inline InteractionOut T3Ie_Recombination::do_Interaction (Particle *interPart) { InteractionOut res; res.set_delete_current(true); - /* + double E_eV = calc_E_eV_from_v_ms(Population->roll_v_ms(interPart->get_x_m()), me_eV); // should be computed properly using chances. Population->decrease_denisty(interPart->get_x_m(), E_eV); - */ + return res; } diff --git a/src/mc_electron/T5Ie_recombination.h b/src/mc_electron/T5Ie_recombination.h index 66a4a87..a707189 100644 --- a/src/mc_electron/T5Ie_recombination.h +++ b/src/mc_electron/T5Ie_recombination.h @@ -28,10 +28,10 @@ public: inline InteractionOut T5Ie_Recombination::do_Interaction (Particle *interPart) { InteractionOut res; res.set_delete_current(true); - /* + double E_eV = calc_E_eV_from_v_ms(Population->roll_v_ms(interPart->get_x_m()), me_eV); // should be computed properly using chances. Population->decrease_denisty(interPart->get_x_m(), E_eV); - */ + return res; } diff --git a/src/mc_electron/eT2I_disexc.h b/src/mc_electron/eT2I_disexc.h index 7450ad3..5d19207 100644 --- a/src/mc_electron/eT2I_disexc.h +++ b/src/mc_electron/eT2I_disexc.h @@ -25,7 +25,7 @@ inline InteractionOut eT2I_DissExc::do_Interaction (Particle *interPart) { InteractionOut res = Excitation_Base::do_Interaction(interPart); vec3 loc_m = interPart->get_x_m(); - //Population->decrease_denisty(interPart->get_x_m(), 0); // dummy since thermal population + Population->decrease_denisty(interPart->get_x_m(), 0); // dummy since thermal population vec3 vTI_ms = Population->roll_v_ms(loc_m); Particle TI = Particle_Builder::create_TI(loc_m, vTI_ms, -1, interPart->get_Id()); diff --git a/src/mc_electron/eT2I_recombination.h b/src/mc_electron/eT2I_recombination.h index d936503..6e38bf7 100644 --- a/src/mc_electron/eT2I_recombination.h +++ b/src/mc_electron/eT2I_recombination.h @@ -27,7 +27,7 @@ inline InteractionOut eT2I_Recombination::do_Interaction (Particle *interPart) { InteractionOut res; res.set_delete_current(true); //std::cout<<"eT2I:\t"<<*interPart<<"\n"; - //Population->decrease_denisty(interPart->get_x_m(), 0); + Population->decrease_denisty(interPart->get_x_m(), 0); return res; } diff --git a/src/mc_electron/eT3I_disexc.h b/src/mc_electron/eT3I_disexc.h index e5ee67b..bd9f77d 100644 --- a/src/mc_electron/eT3I_disexc.h +++ b/src/mc_electron/eT3I_disexc.h @@ -24,7 +24,7 @@ public: inline InteractionOut eT3I_DissExc::do_Interaction (Particle *interPart) { InteractionOut res = Excitation_Base::do_Interaction(interPart); vec3 loc_m = interPart->get_x_m(); - //Population->decrease_denisty(loc_m, 0); // dummy since thermal population + Population->decrease_denisty(loc_m, 0); // dummy since thermal population vec3 vTI_ms = Population->roll_v_ms(loc_m); Particle TI = Particle_Builder::create_TI(loc_m, vTI_ms, -1, interPart->get_Id()); diff --git a/src/mc_electron/eT3I_recombination.h b/src/mc_electron/eT3I_recombination.h index 9d19e89..10b2135 100644 --- a/src/mc_electron/eT3I_recombination.h +++ b/src/mc_electron/eT3I_recombination.h @@ -25,7 +25,7 @@ inline InteractionOut eT3I_Recombination::do_Interaction (Particle *interPart) { InteractionOut res; res.set_delete_current(true); //std::cout<<"eT3I:\t"<<*interPart<<"\n"; - //Population->decrease_denisty(interPart->get_x_m(), 0); + Population->decrease_denisty(interPart->get_x_m(), 0); return res; } diff --git a/src/mc_electron/eT5I_recombination.h b/src/mc_electron/eT5I_recombination.h index 4dd1baf..87820e5 100644 --- a/src/mc_electron/eT5I_recombination.h +++ b/src/mc_electron/eT5I_recombination.h @@ -27,7 +27,7 @@ inline InteractionOut eT5I_Recombination::do_Interaction (Particle *interPart) { InteractionOut res; //std::cout<<"eT5I:\t"<<*interPart<<"\n"; res.set_delete_current(true); - //Population->decrease_denisty(interPart->get_x_m(), 0); + Population->decrease_denisty(interPart->get_x_m(), 0); return res; } diff --git a/src/mc_electron/sub_interaction_base.h b/src/mc_electron/sub_interaction_base.h index b130e86..99338e4 100644 --- a/src/mc_electron/sub_interaction_base.h +++ b/src/mc_electron/sub_interaction_base.h @@ -86,7 +86,8 @@ inline double Sub_Interaction_Base::get_macroSigma_m_kinetic(const Particle &int vec3 loc_m = interPart.get_x_m(); Content cont; double macro_Sigma_m2 = 0; - for (int E_bin = 0; E_bin< bounds.num_E_bins; E_bin++) { + for (int E_bin = 0; E_binget_density_m3(E_bin, bounds.loc_bins); macro_Sigma_m2 += get_microSigma_m2(cont.E_eV, loc_m) * cont.n_m3; } return macro_Sigma_m2;