diff options
author | 2021-01-15 13:24:08 -0800 | |
---|---|---|
committer | 2021-01-15 13:24:08 -0800 | |
commit | 6f9790baf7002a271b15c7de0e81a12a87ecff73 (patch) | |
tree | cf033c6276792c82d07a3d173d8365e3232e1627 /Source/Parallelization | |
parent | 3af650078efea347ef4522060ef8ca88b2e1e17d (diff) | |
download | WarpX-6f9790baf7002a271b15c7de0e81a12a87ecff73.tar.gz WarpX-6f9790baf7002a271b15c7de0e81a12a87ecff73.tar.zst WarpX-6f9790baf7002a271b15c7de0e81a12a87ecff73.zip |
Fix bug in momentum-conserving interpolation function with MR (#1624)
* Fix bug in momentum-conserving interpolation function
* Reset checksum benchmark for CI test momentum-conserving-gather
Diffstat (limited to 'Source/Parallelization')
-rw-r--r-- | Source/Parallelization/WarpXComm_K.H | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/Source/Parallelization/WarpXComm_K.H b/Source/Parallelization/WarpXComm_K.H index f1175c8b9..092a13565 100644 --- a/Source/Parallelization/WarpXComm_K.H +++ b/Source/Parallelization/WarpXComm_K.H @@ -521,12 +521,17 @@ void warpx_interp_nd_efield_y (int j, int k, int l, #if (AMREX_SPACEDIM == 2) - // interp from coarse nodal and coarse staggered to fine nodal - Real eg = owx * owy * (Eyg(jg ,kg ,0) + Eyc(jg ,kg ,0)) - + owx * wy * (Eyg(jg ,kg+1,0) + Eyc(jg ,kg+1,0)) - + wx * owy * (Eyg(jg+1,kg ,0) + Eyc(jg+1,kg ,0)) - + wx * wy * (Eyg(jg+1,kg+1,0) + Eyc(jg+1,kg+1,0)); - Real ec = 0.0_rt; + // interp from coarse nodal to fine nodal + Real eg = owx * owy * Eyg(jg ,kg ,0) + + owx * wy * Eyg(jg ,kg+1,0) + + wx * owy * Eyg(jg+1,kg ,0) + + wx * wy * Eyg(jg+1,kg+1,0); + + // interp from coarse staggered to fine nodal (Eyc is actually nodal) + Real ec = owx * owy * Eyc(jg ,kg ,0) + + owx * wy * Eyc(jg ,kg+1,0) + + wx * owy * Eyc(jg+1,kg ,0) + + wx * wy * Eyc(jg+1,kg+1,0); // interp from fine staggered to fine nodal Real ef = Eyf(j,k,0); |