diff options
author | 2020-05-22 10:06:39 -0700 | |
---|---|---|
committer | 2020-05-22 10:06:39 -0700 | |
commit | e303439fccf613302780e3e669fa4ac581817529 (patch) | |
tree | 4b128dbdf6fc7f94024daa910acf754bd5296f3c /Source/FieldSolver/SpectralSolver/SpectralAlgorithms/PsatdAlgorithmRZ.H | |
parent | 7996bc9abb52c3231d08dce202855635d55efb6a (diff) | |
download | WarpX-e303439fccf613302780e3e669fa4ac581817529.tar.gz WarpX-e303439fccf613302780e3e669fa4ac581817529.tar.zst WarpX-e303439fccf613302780e3e669fa4ac581817529.zip |
Added stub for current correction in RZ spectral solver (#1007)
* Added stub for current correction in RZ spectral solver
* Fixed comments in RZ spectral for current correction stub
* Modified automated test for Galilean PSATD (#1033)
Co-authored-by: Olga Shapoval <30510597+oshapoval@users.noreply.github.com>
Diffstat (limited to 'Source/FieldSolver/SpectralSolver/SpectralAlgorithms/PsatdAlgorithmRZ.H')
-rw-r--r-- | Source/FieldSolver/SpectralSolver/SpectralAlgorithms/PsatdAlgorithmRZ.H | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/Source/FieldSolver/SpectralSolver/SpectralAlgorithms/PsatdAlgorithmRZ.H b/Source/FieldSolver/SpectralSolver/SpectralAlgorithms/PsatdAlgorithmRZ.H index 309bb050f..6a604155b 100644 --- a/Source/FieldSolver/SpectralSolver/SpectralAlgorithms/PsatdAlgorithmRZ.H +++ b/Source/FieldSolver/SpectralSolver/SpectralAlgorithms/PsatdAlgorithmRZ.H @@ -28,6 +28,22 @@ class PsatdAlgorithmRZ : public SpectralBaseAlgorithmRZ void InitializeSpectralCoefficients(SpectralFieldDataRZ const & f); + /** + * \brief Virtual function for current correction in Fourier space + * (equation (19) of https://doi.org/10.1016/j.jcp.2013.03.010). + * This function overrides the virtual function \c CurrentCorrection in the + * base class \c SpectralBaseAlgorithmRZ (qualifier \c override) and cannot be + * overridden by further derived classes (qualifier \c final). + * + * \param[in,out] field_data all fields in Fourier space + * \param[in,out] current two-dimensional array of unique pointers to MultiFab + * storing the three components of the current density + * \param[in] rho unique pointer to MultiFab storing the charge density + */ + virtual void CurrentCorrection ( SpectralFieldDataRZ& field_data, + std::array<std::unique_ptr<amrex::MultiFab>,3>& current, + const std::unique_ptr<amrex::MultiFab>& rho ) override final; + private: bool coefficients_initialized; // Note that dt is saved to use in InitializeSpectralCoefficients |