aboutsummaryrefslogtreecommitdiff
path: root/Source/FieldSolver/SpectralSolver/SpectralAlgorithms/PMLPsatdAlgorithm.H
diff options
context:
space:
mode:
authorGravatar MaxThevenet <mthevenet@lbl.gov> 2019-08-06 11:23:39 -0700
committerGravatar GitHub <noreply@github.com> 2019-08-06 11:23:39 -0700
commit8d87c45bab74f9bff33731e0e3f9a239a5f53911 (patch)
treef7381153c3d5ebd463586e5d1a13574b133ceb0c /Source/FieldSolver/SpectralSolver/SpectralAlgorithms/PMLPsatdAlgorithm.H
parent0797099828c04e96c88c093b96d22480e5391b06 (diff)
parent90c7a587a87e4411434c0dc6433bc6c5703fe521 (diff)
downloadWarpX-8d87c45bab74f9bff33731e0e3f9a239a5f53911.tar.gz
WarpX-8d87c45bab74f9bff33731e0e3f9a239a5f53911.tar.zst
WarpX-8d87c45bab74f9bff33731e0e3f9a239a5f53911.zip
Merge pull request #122 from ECP-WarpX/psatd_pml
PSATD solver in PML
Diffstat (limited to 'Source/FieldSolver/SpectralSolver/SpectralAlgorithms/PMLPsatdAlgorithm.H')
-rw-r--r--Source/FieldSolver/SpectralSolver/SpectralAlgorithms/PMLPsatdAlgorithm.H34
1 files changed, 34 insertions, 0 deletions
diff --git a/Source/FieldSolver/SpectralSolver/SpectralAlgorithms/PMLPsatdAlgorithm.H b/Source/FieldSolver/SpectralSolver/SpectralAlgorithms/PMLPsatdAlgorithm.H
new file mode 100644
index 000000000..a2511b6b7
--- /dev/null
+++ b/Source/FieldSolver/SpectralSolver/SpectralAlgorithms/PMLPsatdAlgorithm.H
@@ -0,0 +1,34 @@
+#ifndef WARPX_PML_PSATD_ALGORITHM_H_
+#define WARPX_PML_PSATD_ALGORITHM_H_
+
+#include <SpectralBaseAlgorithm.H>
+
+/* \brief Class that updates the field in spectral space
+ * and stores the coefficients of the corresponding update equation.
+ */
+class PMLPsatdAlgorithm : public SpectralBaseAlgorithm
+{
+ public:
+ PMLPsatdAlgorithm(const SpectralKSpace& spectral_kspace,
+ const amrex::DistributionMapping& dm,
+ const int norder_x, const int norder_y,
+ const int norder_z, const bool nodal,
+ const amrex::Real dt);
+
+ void InitializeSpectralCoefficients(
+ const SpectralKSpace& spectral_kspace,
+ const amrex::DistributionMapping& dm,
+ const amrex::Real dt);
+
+ // Redefine functions from base class
+ virtual void pushSpectralFields(SpectralFieldData& f) const override final;
+ virtual int getRequiredNumberOfFields() const override final {
+ return SpectralPMLIndex::n_fields;
+ }
+
+ private:
+ SpectralCoefficients C_coef, S_ck_coef;
+
+};
+
+#endif // WARPX_PML_PSATD_ALGORITHM_H_