diff options
author | 2019-08-21 09:14:21 -0700 | |
---|---|---|
committer | 2019-08-21 09:14:21 -0700 | |
commit | 16dd4d0491b32fb669a1ee07ed2866f68aafd6da (patch) | |
tree | bc3fcb1c4617df10b3ad047ae8034e44ca9625e7 /Source/Laser/LaserParticleContainer.cpp | |
parent | 5ec7a45b2a2ae43b83b4c695db1e7b2a3bbb805c (diff) | |
download | WarpX-16dd4d0491b32fb669a1ee07ed2866f68aafd6da.tar.gz WarpX-16dd4d0491b32fb669a1ee07ed2866f68aafd6da.tar.zst WarpX-16dd4d0491b32fb669a1ee07ed2866f68aafd6da.zip |
charge deposition depends on ionization level
Diffstat (limited to 'Source/Laser/LaserParticleContainer.cpp')
-rw-r--r-- | Source/Laser/LaserParticleContainer.cpp | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/Source/Laser/LaserParticleContainer.cpp b/Source/Laser/LaserParticleContainer.cpp index e9a2d42de..9fac71894 100644 --- a/Source/Laser/LaserParticleContainer.cpp +++ b/Source/Laser/LaserParticleContainer.cpp @@ -454,9 +454,10 @@ LaserParticleContainer::Evolve (int lev, BL_PROFILE_VAR_STOP(blp_copy); if (rho) { - DepositCharge(pti, wp, rho, 0, 0, np_current, thread_num, lev, lev); + int* AMREX_RESTRICT ion_lev = nullptr; if (crho) { - DepositCharge(pti, wp, crho, 0, np_current, np-np_current, thread_num, lev, lev-1); + DepositCharge(pti, wp, ion_lev, crho, 0, np_current, + np-np_current, thread_num, lev, lev-1); } } @@ -529,9 +530,12 @@ LaserParticleContainer::Evolve (int lev, BL_PROFILE_VAR_STOP(blp_copy); if (rho) { - DepositCharge(pti, wp, rho, 1, 0, np_current, thread_num, lev, lev); + int* AMREX_RESTRICT ion_lev = nullptr; + DepositCharge(pti, wp, ion_lev, rho, 1, 0, + np_current, thread_num, lev, lev); if (crho) { - DepositCharge(pti, wp, crho, 1, np_current, np-np_current, thread_num, lev, lev-1); + DepositCharge(pti, wp, ion_lev, crho, 1, np_current, + np-np_current, thread_num, lev, lev-1); } } |