68{
69 const G4double R2 = __reactionRadius * __reactionRadius;
71 bool do_break = false;
72 int k = 0;
73
74 for (; k < 3; ++k)
75 {
76 postStepSeparation += std::pow(
78
79 if (postStepSeparation > R2)
80 {
81 do_break = true;
82 break;
83 }
84 }
85
86 if (!do_break)
87 {
88
89
90 __separationDistance = std::sqrt(postStepSeparation);
91 return true;
92 }
93 if (__alongStepReaction)
94 {
95
96
97
98 for (; k < 3; ++k)
99 {
100 postStepSeparation += std::pow(
102 }
103
104 __separationDistance = (postStepSeparation = std::sqrt(postStepSeparation));
105
108
109 G4double D = pMoleculeA->GetDiffusionCoefficient()
110 + pMoleculeB->GetDiffusionCoefficient();
111
114
115 G4double preStepSeparation = (preStepPositionA - preStepPositionB).mag();
116
117
118
119 G4double __probabiltyOfEncounter =
G4Exp(-(preStepSeparation - __reactionRadius)
120 * (postStepSeparation - __reactionRadius)
122 );
124
125 if (__selectedPOE <= __probabiltyOfEncounter)
126 {
127 return true;
128 }
129
130 }
131
132 return false;
133}
G4double D(G4double temp)
G4double G4Exp(G4double initial_x)
Exponential Function double precision.
G4Molecule * GetMolecule(const G4Track &track)
const G4ThreeVector & GetPosition() const
G4double GetDeltaTime() const
G4StepPoint * GetPreStepPoint() const
const G4ThreeVector & GetPosition() const
const G4Step * GetStep() const