1919MultiphotonBreitWheeler::MultiphotonBreitWheeler (Params& params, Species * species)
2020{
2121 // Dimension position
22- nDim_ = params.nDim_particle ;
22+ n_dimensions_ = params.nDim_particle ;
2323
2424 // Time step
2525 dt = params.timestep ;
2626
2727 // Normalized Schwinger Electric Field
28- norm_E_Schwinger = params.electron_mass *params.c_vacuum *params.c_vacuum
28+ norm_E_Schwinger_ = params.electron_mass *params.c_vacuum *params.c_vacuum
2929 / (params.red_planck_cst *params.reference_angular_frequency_SI );
3030
31- // Inverse of norm_E_Schwinger
32- inv_norm_E_Schwinger = 1 ./norm_E_Schwinger ;
31+ // Inverse of norm_E_Schwinger_
32+ inv_norm_E_Schwinger_ = 1 ./norm_E_Schwinger_ ;
3333
3434 // Number of positrons and electrons generated per event
3535 this ->mBW_pair_creation_sampling [0 ] = species->mBW_pair_creation_sampling [0 ];
@@ -161,7 +161,7 @@ void MultiphotonBreitWheeler::operator() (Particles &particles,
161161 // for now particles could be created outside of the local domain
162162 // without been subject do boundary conditions (including domain exchange)
163163 // double* position[3];
164- // for ( int i = 0 ; i<nDim_ ; i++ )
164+ // for ( int i = 0 ; i<n_dimensions_ ; i++ )
165165 // position[i] = &( particles.position(i,0) );
166166
167167 // Weight shortcut
@@ -171,7 +171,7 @@ void MultiphotonBreitWheeler::operator() (Particles &particles,
171171 double * tau = &( particles.tau (0 ));
172172
173173 // Quantum parameter
174- double * chiph = &( particles.chi (0 ));
174+ double * photon_chi = &( particles.chi (0 ));
175175
176176 // Photon id
177177 // uint64_t * id = &( particles.id(0));
@@ -193,7 +193,7 @@ void MultiphotonBreitWheeler::operator() (Particles &particles,
193193 + momentum[2 ][ipart]*momentum[2 ][ipart]);
194194
195195 // Computation of the Lorentz invariant quantum parameter
196- chiph [ipart] = MultiphotonBreitWheeler::compute_chiph (
196+ photon_chi [ipart] = MultiphotonBreitWheeler::compute_chiph (
197197 momentum[0 ][ipart],momentum[1 ][ipart],momentum[2 ][ipart],
198198 (*gamma)[ipart],
199199 (*(Ex+ipart-ipart_ref)),(*(Ey+ipart-ipart_ref)),(*(Ez+ipart-ipart_ref)),
@@ -206,29 +206,29 @@ void MultiphotonBreitWheeler::operator() (Particles &particles,
206206 {
207207
208208 // If the photon has enough energy
209- // We also check that chiph > chiph_threshold,
210- // else chiph is too low to induce a decay
211- if (((*gamma)[ipart] > 2 .) && (chiph [ipart] > chiph_threashold))
209+ // We also check that photon_chi > chiph_threshold,
210+ // else photon_chi is too low to induce a decay
211+ if (((*gamma)[ipart] > 2 .) && (photon_chi [ipart] > chiph_threashold))
212212 {
213213 // Init local variables
214214 event_time = 0 ;
215215
216216 // New even
217217 // If tau[ipart] <= 0, this is a new process
218- if (tau[ipart] <= epsilon_tau )
218+ if (tau[ipart] <= epsilon_tau_ )
219219 {
220220 // New final optical depth to reach for emision
221- while (tau[ipart] <= epsilon_tau )
221+ while (tau[ipart] <= epsilon_tau_ )
222222 tau[ipart] = -log (1 .-Rand::uniform ());
223223
224224 }
225225
226226 // Photon decay: emission under progress
227- // If epsilon_tau > 0
228- else if (tau[ipart] > epsilon_tau )
227+ // If epsilon_tau_ > 0
228+ else if (tau[ipart] > epsilon_tau_ )
229229 {
230230 // from the cross section
231- temp = MultiphotonBreitWheelerTables.compute_dNBWdt (chiph [ipart],(*gamma)[ipart]);
231+ temp = MultiphotonBreitWheelerTables.compute_dNBWdt (photon_chi [ipart],(*gamma)[ipart]);
232232
233233 // Time to decay
234234 // If this time is above the remaining iteration time,
@@ -241,17 +241,17 @@ void MultiphotonBreitWheeler::operator() (Particles &particles,
241241
242242 // If the final optical depth is reached
243243 // The photon decays into pairs
244- if (tau[ipart] <= epsilon_tau )
244+ if (tau[ipart] <= epsilon_tau_ )
245245 {
246246
247247 // Update of the position
248248 // Move the photons
249249
250250// #ifdef __DEBUG
251- // for ( int i = 0 ; i<nDim_ ; i++ )
251+ // for ( int i = 0 ; i<n_dimensions_ ; i++ )
252252// particles.position_old(i,ipart) = position[i][ipart];
253253// #endif
254- // for ( int i = 0 ; i<nDim_ ; i++ )
254+ // for ( int i = 0 ; i<n_dimensions_ ; i++ )
255255// position[i][ipart] += event_time*momentum[i][ipart]/(*gamma)[ipart];
256256
257257
@@ -343,14 +343,14 @@ void MultiphotonBreitWheeler::pair_emission(int ipart,
343343 // inv_gamma = 1./sqrt(1.+p*p);
344344
345345 // Positions
346- for (i=0 ; i<nDim_ ; i++) {
346+ for (i=0 ; i<n_dimensions_ ; i++) {
347347 new_pair[k].position (i,idNew)=particles.position (i,ipart);
348348// + new_pair[k].momentum(i,idNew)*remaining_dt*inv_gamma;
349349 }
350350
351351 // Old positions
352352#ifdef __DEBUG
353- for (i=0 ; i<nDim_ ; i++) {
353+ for (i=0 ; i<n_dimensions_ ; i++) {
354354 new_pair[k].position_old (i,idNew)=particles.position (i,ipart) ;
355355 }
356356#endif
0 commit comments