Fixed bug in recombination calculation and activated offsets.
This commit is contained in:
@@ -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());
|
Particle TI = Particle_Builder::create_TI(loc_m, vTI_ms, -1, interPart->get_Id());
|
||||||
res.add_new_particle(TI);
|
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.
|
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;
|
return res;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -25,10 +25,10 @@ public:
|
|||||||
inline InteractionOut T2Ie_Recombination::do_Interaction (Particle *interPart) {
|
inline InteractionOut T2Ie_Recombination::do_Interaction (Particle *interPart) {
|
||||||
InteractionOut res;
|
InteractionOut res;
|
||||||
res.set_delete_current(true);
|
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.
|
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);
|
Population->decrease_denisty(interPart->get_x_m(), E_eV);
|
||||||
*/
|
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -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());
|
Particle TI = Particle_Builder::create_TI(loc_m, vTI_ms, -1, interPart->get_Id());
|
||||||
res.add_new_particle(TI);
|
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.
|
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;
|
return res;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -24,10 +24,10 @@ public:
|
|||||||
inline InteractionOut T3Ie_Recombination::do_Interaction (Particle *interPart) {
|
inline InteractionOut T3Ie_Recombination::do_Interaction (Particle *interPart) {
|
||||||
InteractionOut res;
|
InteractionOut res;
|
||||||
res.set_delete_current(true);
|
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.
|
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);
|
Population->decrease_denisty(interPart->get_x_m(), E_eV);
|
||||||
*/
|
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -28,10 +28,10 @@ public:
|
|||||||
inline InteractionOut T5Ie_Recombination::do_Interaction (Particle *interPart) {
|
inline InteractionOut T5Ie_Recombination::do_Interaction (Particle *interPart) {
|
||||||
InteractionOut res;
|
InteractionOut res;
|
||||||
res.set_delete_current(true);
|
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.
|
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);
|
Population->decrease_denisty(interPart->get_x_m(), E_eV);
|
||||||
*/
|
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -25,7 +25,7 @@ inline InteractionOut eT2I_DissExc::do_Interaction (Particle *interPart) {
|
|||||||
InteractionOut res = Excitation_Base::do_Interaction(interPart);
|
InteractionOut res = Excitation_Base::do_Interaction(interPart);
|
||||||
|
|
||||||
vec3 loc_m = interPart->get_x_m();
|
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);
|
vec3 vTI_ms = Population->roll_v_ms(loc_m);
|
||||||
Particle TI = Particle_Builder::create_TI(loc_m, vTI_ms, -1, interPart->get_Id());
|
Particle TI = Particle_Builder::create_TI(loc_m, vTI_ms, -1, interPart->get_Id());
|
||||||
|
|||||||
@@ -27,7 +27,7 @@ inline InteractionOut eT2I_Recombination::do_Interaction (Particle *interPart) {
|
|||||||
InteractionOut res;
|
InteractionOut res;
|
||||||
res.set_delete_current(true);
|
res.set_delete_current(true);
|
||||||
//std::cout<<"eT2I:\t"<<*interPart<<"\n";
|
//std::cout<<"eT2I:\t"<<*interPart<<"\n";
|
||||||
//Population->decrease_denisty(interPart->get_x_m(), 0);
|
Population->decrease_denisty(interPart->get_x_m(), 0);
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ public:
|
|||||||
inline InteractionOut eT3I_DissExc::do_Interaction (Particle *interPart) {
|
inline InteractionOut eT3I_DissExc::do_Interaction (Particle *interPart) {
|
||||||
InteractionOut res = Excitation_Base::do_Interaction(interPart);
|
InteractionOut res = Excitation_Base::do_Interaction(interPart);
|
||||||
vec3 loc_m = interPart->get_x_m();
|
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);
|
vec3 vTI_ms = Population->roll_v_ms(loc_m);
|
||||||
Particle TI = Particle_Builder::create_TI(loc_m, vTI_ms, -1, interPart->get_Id());
|
Particle TI = Particle_Builder::create_TI(loc_m, vTI_ms, -1, interPart->get_Id());
|
||||||
|
|||||||
@@ -25,7 +25,7 @@ inline InteractionOut eT3I_Recombination::do_Interaction (Particle *interPart) {
|
|||||||
InteractionOut res;
|
InteractionOut res;
|
||||||
res.set_delete_current(true);
|
res.set_delete_current(true);
|
||||||
//std::cout<<"eT3I:\t"<<*interPart<<"\n";
|
//std::cout<<"eT3I:\t"<<*interPart<<"\n";
|
||||||
//Population->decrease_denisty(interPart->get_x_m(), 0);
|
Population->decrease_denisty(interPart->get_x_m(), 0);
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -27,7 +27,7 @@ inline InteractionOut eT5I_Recombination::do_Interaction (Particle *interPart) {
|
|||||||
InteractionOut res;
|
InteractionOut res;
|
||||||
//std::cout<<"eT5I:\t"<<*interPart<<"\n";
|
//std::cout<<"eT5I:\t"<<*interPart<<"\n";
|
||||||
res.set_delete_current(true);
|
res.set_delete_current(true);
|
||||||
//Population->decrease_denisty(interPart->get_x_m(), 0);
|
Population->decrease_denisty(interPart->get_x_m(), 0);
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -87,6 +87,7 @@ inline double Sub_Interaction_Base::get_macroSigma_m_kinetic(const Particle &int
|
|||||||
Content cont;
|
Content cont;
|
||||||
double macro_Sigma_m2 = 0;
|
double macro_Sigma_m2 = 0;
|
||||||
for (int E_bin = 0; E_bin<bounds.num_E_bins; E_bin++) {
|
for (int E_bin = 0; E_bin<bounds.num_E_bins; E_bin++) {
|
||||||
|
cont = Population->get_density_m3(E_bin, bounds.loc_bins);
|
||||||
macro_Sigma_m2 += get_microSigma_m2(cont.E_eV, loc_m) * cont.n_m3;
|
macro_Sigma_m2 += get_microSigma_m2(cont.E_eV, loc_m) * cont.n_m3;
|
||||||
}
|
}
|
||||||
return macro_Sigma_m2;
|
return macro_Sigma_m2;
|
||||||
|
|||||||
Reference in New Issue
Block a user