aboutsummaryrefslogtreecommitdiff
path: root/Source/FieldSolver/SpectralSolver
diff options
context:
space:
mode:
authorGravatar Remi Lehe <remi.lehe@normalesup.org> 2019-04-19 20:50:38 -0700
committerGravatar Remi Lehe <remi.lehe@normalesup.org> 2019-04-23 12:43:53 -0700
commite54e25a2cf23007bc8132b87079664fcf891fdfb (patch)
tree63fe217ad173c0b75e18063238e3454c92bc5f4c /Source/FieldSolver/SpectralSolver
parent0b77b789043461c77780ab56ab46a1e564b98d6e (diff)
downloadWarpX-e54e25a2cf23007bc8132b87079664fcf891fdfb.tar.gz
WarpX-e54e25a2cf23007bc8132b87079664fcf891fdfb.tar.zst
WarpX-e54e25a2cf23007bc8132b87079664fcf891fdfb.zip
Fix NaN issue
Diffstat (limited to 'Source/FieldSolver/SpectralSolver')
-rw-r--r--Source/FieldSolver/SpectralSolver/SpectralKSpace.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/Source/FieldSolver/SpectralSolver/SpectralKSpace.cpp b/Source/FieldSolver/SpectralSolver/SpectralKSpace.cpp
index 2b1e7ee33..d05748192 100644
--- a/Source/FieldSolver/SpectralSolver/SpectralKSpace.cpp
+++ b/Source/FieldSolver/SpectralSolver/SpectralKSpace.cpp
@@ -8,7 +8,10 @@ SpectralKSpace::SpectralKSpace( const BoxArray& realspace_ba,
const DistributionMapping& dm,
const Array<Real,3> realspace_dx )
{
- // Create the box array that corresponds to spectral space
+ // Store the cell size
+ dx = realspace_dx;
+
+ // Create the box array that corresponds to spectral space
BoxList spectral_bl; // Create empty box list
// Loop over boxes and fill the box list
for (int i=0; i < realspace_ba.size(); i++ ) {
@@ -31,9 +34,6 @@ SpectralKSpace::SpectralKSpace( const BoxArray& realspace_ba,
AllocateAndFillKvector( ky_vec[mfi], bx, dx, 1 );
AllocateAndFillKvector( kz_vec[mfi], bx, dx, 2 );
}
-
- // Store the cell size
- dx = realspace_dx;
}
void