Go to the source code of this file.
|
| template<typename T_ParticleContainer> |
| void | particlesConvertUnits (ConvertDirection convert_direction, T_ParticleContainer *pc, amrex::ParticleReal const mass) |
| |
| void | storePhiOnParticles (WarpXParticleContainer::Base &tmp, ElectrostaticSolverAlgo electrostatic_solver_id, bool is_full_diagnostic) |
| |
| void | storeFieldOnParticles (WarpXParticleContainer::Base &tmp, bool is_full_diagnostic, bool save_Ex, bool save_Ey, bool save_Ez, bool save_Bx, bool save_By, bool save_Bz) |
| | Gathers fields from a MultiFab to the macroparticles. Adds a runtime component of the particle container to store it.
|
| |
◆ ConvertDirection
| Enumerator |
|---|
| WarpX_to_SI | |
| SI_to_WarpX | |
◆ particlesConvertUnits()
template<typename T_ParticleContainer>
Convert particle momentum to/from SI
Particle momentum is defined as gamma*velocity, which is neither SI mass*gamma*velocity nor normalized gamma*velocity/c. This converts momentum to SI units (or vice-versa) to write SI data to file. Photons are a special case, since particle momentum is defined as (photon_energy/(m_e * c) ) * u, where u is the photon direction (a unit vector).
- Template Parameters
-
| T_ParticleContainer | a WarpX particle container or AmrParticleContainer |
- Parameters
-
| convert_direction | convert to or from SI |
| pc | the particle container to manipulate |
| mass | the particle rest mass to use for conversion |
◆ storeFieldOnParticles()
| void storeFieldOnParticles |
( |
WarpXParticleContainer::Base & | tmp, |
|
|
bool | is_full_diagnostic, |
|
|
bool | save_Ex, |
|
|
bool | save_Ey, |
|
|
bool | save_Ez, |
|
|
bool | save_Bx, |
|
|
bool | save_By, |
|
|
bool | save_Bz ) |
Gathers fields from a MultiFab to the macroparticles. Adds a runtime component of the particle container to store it.
- Parameters
-
| tmp | The particle container on which to store the gathered field |
| is_full_diagnostic | Whether this diagnostic is a full diagnostic |
| save_Ex | Whether the Ex field is saved |
| save_Ey | Whether the Ex field is saved |
| save_Ez | Whether the Ex field is saved |
| save_Bx | Whether the Ex field is saved |
| save_By | Whether the Ex field is saved |
| save_Bz | Whether the Ex field is saved |
◆ storePhiOnParticles()
Gathers phi (electrostatic potential) from a MultiFab to the macroparticles. Adds a runtime component of the particle container to store it.
- Parameters
-
| tmp | the particle container on which to store the gathered field |
| electrostatic_solver_id | the type of electrostatic solver used |
| is_full_diagnostic | whether this diagnostic is a full diagnostic |