aboutsummaryrefslogtreecommitdiff
path: root/Source/Particles/PhysicalParticleContainer.cpp
diff options
context:
space:
mode:
authorGravatar Dave Grote <grote1@llnl.gov> 2019-07-15 16:53:09 -0700
committerGravatar Dave Grote <grote1@llnl.gov> 2019-07-15 16:53:09 -0700
commit89c5652f379a4ed1f4f4f134d0b0dd68d84da77d (patch)
tree0cdbf8f4723b0effb019d984027db909d668e20d /Source/Particles/PhysicalParticleContainer.cpp
parent5d60565382ea2369fab6c5959ecf0a05c6a53e74 (diff)
parent9644af5ed2eeeadbfb34dea9fdb2d5bbd5d2b34d (diff)
downloadWarpX-89c5652f379a4ed1f4f4f134d0b0dd68d84da77d.tar.gz
WarpX-89c5652f379a4ed1f4f4f134d0b0dd68d84da77d.tar.zst
WarpX-89c5652f379a4ed1f4f4f134d0b0dd68d84da77d.zip
Merge branch 'dev' into push_momentum
Diffstat (limited to 'Source/Particles/PhysicalParticleContainer.cpp')
-rw-r--r--Source/Particles/PhysicalParticleContainer.cpp31
1 files changed, 22 insertions, 9 deletions
diff --git a/Source/Particles/PhysicalParticleContainer.cpp b/Source/Particles/PhysicalParticleContainer.cpp
index 280d0ca1b..a1d9a9afb 100644
--- a/Source/Particles/PhysicalParticleContainer.cpp
+++ b/Source/Particles/PhysicalParticleContainer.cpp
@@ -1535,15 +1535,28 @@ PhysicalParticleContainer::Evolve (int lev,
//
// Current Deposition
//
- // Deposit inside domains
- DepositCurrent(pti, wp, uxp, uyp, uzp, &jx, &jy, &jz,
- 0, np_current, thread_num,
- lev, lev, dt);
- if (has_buffer){
- // Deposit in buffers
- DepositCurrent(pti, wp, uxp, uyp, uzp, cjx, cjy, cjz,
- np_current, np-np_current, thread_num,
- lev, lev-1, dt);
+ if (WarpX::use_picsar_deposition) {
+ // Deposit inside domains
+ DepositCurrentFortran(pti, wp, uxp, uyp, uzp, &jx, &jy, &jz,
+ 0, np_current, thread_num,
+ lev, lev, dt);
+ if (has_buffer){
+ // Deposit in buffers
+ DepositCurrentFortran(pti, wp, uxp, uyp, uzp, cjx, cjy, cjz,
+ np_current, np-np_current, thread_num,
+ lev, lev-1, dt);
+ }
+ } else {
+ // Deposit inside domains
+ DepositCurrent(pti, wp, uxp, uyp, uzp, &jx, &jy, &jz,
+ 0, np_current, thread_num,
+ lev, lev, dt);
+ if (has_buffer){
+ // Deposit in buffers
+ DepositCurrent(pti, wp, uxp, uyp, uzp, cjx, cjy, cjz,
+ np_current, np-np_current, thread_num,
+ lev, lev-1, dt);
+ }
}
//