Added Excitation for Electrons:
Rotational J=0->2 Vibrational v=0->1 Electrical various (7 in total, see Paper from Janev 2008 for details)
This commit is contained in:
@@ -38,23 +38,24 @@ public:
|
||||
inline InteractionOut Interaction_Base::do_Interaction(Particle *interPart) {
|
||||
double macroSigma_m2 = get_macroSigma_m2(*interPart);
|
||||
|
||||
double currentStackedSigma = zero;
|
||||
double currentStackedSigma = 0;
|
||||
double targetStackedSigma = rngUni->random() * macroSigma_m2;
|
||||
|
||||
|
||||
for (int i = 0; i < numSubInteractions; i++) {
|
||||
currentStackedSigma += SubInteractions[i]->get_macroSigma_m2(*interPart);
|
||||
if (currentStackedSigma > targetStackedSigma) {
|
||||
if (currentStackedSigma >= targetStackedSigma) {
|
||||
return (SubInteractions[i]->do_Interaction(interPart));
|
||||
}
|
||||
}
|
||||
std::cout<<interPart->get_species()<<"\n";
|
||||
std::stringstream ss;
|
||||
ss<<"Interaction_Base::do_Interactio: No Interaction selected.\n";
|
||||
ss<<"Interaction_Base::do_Interaction: No Interactions added.\n";
|
||||
throw MyException (ss.str());
|
||||
}
|
||||
|
||||
inline double Interaction_Base::get_macroSigma_m2(const Particle &interPart) {
|
||||
double macroSigma_m2 = zero;
|
||||
double macroSigma_m2 = 0;
|
||||
for (int i = 0; i < numSubInteractions; i++) {
|
||||
macroSigma_m2 += SubInteractions[i]->get_macroSigma_m2(interPart);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user