diff options
author | 2020-07-06 11:26:41 -0700 | |
---|---|---|
committer | 2020-07-06 11:26:41 -0700 | |
commit | 345feb7faa0647ec52025adb450c2855154e8111 (patch) | |
tree | 10fc5525a86b9aacfef9ef537d0ee363ec505c55 /Source/FieldSolver/SpectralSolver/SpectralSolver.cpp | |
parent | 0a146f12b7a18159561bc74595a3853063216d3c (diff) | |
download | WarpX-345feb7faa0647ec52025adb450c2855154e8111.tar.gz WarpX-345feb7faa0647ec52025adb450c2855154e8111.tar.zst WarpX-345feb7faa0647ec52025adb450c2855154e8111.zip |
PSATD: add option to update E without using rho (#1128)
* Introduce option to update E with/without rho
* Clean up
* Include equations in docs
* Fix EOL whitespaces error
* Small clean-up
* Clean up
Diffstat (limited to 'Source/FieldSolver/SpectralSolver/SpectralSolver.cpp')
-rw-r--r-- | Source/FieldSolver/SpectralSolver/SpectralSolver.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Source/FieldSolver/SpectralSolver/SpectralSolver.cpp b/Source/FieldSolver/SpectralSolver/SpectralSolver.cpp index 7b6ab83e8..0be623eed 100644 --- a/Source/FieldSolver/SpectralSolver/SpectralSolver.cpp +++ b/Source/FieldSolver/SpectralSolver/SpectralSolver.cpp @@ -37,7 +37,8 @@ SpectralSolver::SpectralSolver( const int norder_z, const bool nodal, const amrex::Array<amrex::Real,3>& v_galilean, const amrex::RealVect dx, const amrex::Real dt, - const bool pml, const bool periodic_single_box ) { + const bool pml, const bool periodic_single_box, + const bool update_with_rho ) { // Initialize all structures using the same distribution mapping dm @@ -55,7 +56,7 @@ SpectralSolver::SpectralSolver( } else if ((v_galilean[0]==0) && (v_galilean[1]==0) && (v_galilean[2]==0)){ // v_galilean is 0: use standard PSATD algorithm algorithm = std::unique_ptr<PsatdAlgorithm>( new PsatdAlgorithm( - k_space, dm, norder_x, norder_y, norder_z, nodal, dt ) ); + k_space, dm, norder_x, norder_y, norder_z, nodal, dt, update_with_rho ) ); } else { // Otherwise: use the Galilean algorithm algorithm = std::unique_ptr<GalileanAlgorithm>( new GalileanAlgorithm( |