aboutsummaryrefslogtreecommitdiff
path: root/Source/FieldSolver/SpectralSolver/SpectralSolver.H
diff options
context:
space:
mode:
Diffstat (limited to 'Source/FieldSolver/SpectralSolver/SpectralSolver.H')
-rw-r--r--Source/FieldSolver/SpectralSolver/SpectralSolver.H15
1 files changed, 15 insertions, 0 deletions
diff --git a/Source/FieldSolver/SpectralSolver/SpectralSolver.H b/Source/FieldSolver/SpectralSolver/SpectralSolver.H
index 08eef19ad..6a6410d49 100644
--- a/Source/FieldSolver/SpectralSolver/SpectralSolver.H
+++ b/Source/FieldSolver/SpectralSolver/SpectralSolver.H
@@ -67,6 +67,21 @@ class SpectralSolver
algorithm->ComputeSpectralDivE( field_data, Efield, divE );
};
+ /**
+ * \brief Public interface to call the virtual function \c CurrentCorrection,
+ * defined in the base class SpectralBaseAlgorithm and possibly overridden
+ * by its derived classes (e.g. PsatdAlgorithm, PMLPsatdAlgorithm), from
+ * objects of class SpectralSolver through the private unique pointer \c algorithm
+ *
+ * \param[in,out] current three-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
+ */
+ void CurrentCorrection ( std::array<std::unique_ptr<amrex::MultiFab>,3>& current,
+ const std::unique_ptr<amrex::MultiFab>& rho ) {
+ algorithm->CurrentCorrection( field_data, current, rho );
+ };
+
private:
// Store field in spectral space and perform the Fourier transforms