From e55fef18dea27108247024fffba4fccd84206ac2 Mon Sep 17 00:00:00 2001 From: Olga Shapoval <30510597+oshapoval@users.noreply.github.com> Date: Mon, 22 Nov 2021 16:42:37 -0800 Subject: Added abort error message to prevent using averaged Galilean PSATD with psatd.update_with_rho=0 (#2571) --- .../FieldSolver/SpectralSolver/SpectralAlgorithms/PsatdAlgorithm.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'Source/FieldSolver/SpectralSolver/SpectralAlgorithms/PsatdAlgorithm.cpp') diff --git a/Source/FieldSolver/SpectralSolver/SpectralAlgorithms/PsatdAlgorithm.cpp b/Source/FieldSolver/SpectralSolver/SpectralAlgorithms/PsatdAlgorithm.cpp index 4fc2910db..395f164cc 100644 --- a/Source/FieldSolver/SpectralSolver/SpectralAlgorithms/PsatdAlgorithm.cpp +++ b/Source/FieldSolver/SpectralSolver/SpectralAlgorithms/PsatdAlgorithm.cpp @@ -112,6 +112,10 @@ PsatdAlgorithm::PsatdAlgorithm( { amrex::Abort("PSATD: warpx.do_divb_cleaning = 1 implemented only with psatd.J_linear_in_time = 1"); } + if (time_averaging && !update_with_rho) + { + amrex::Abort("PSATD: warpx.time_averaging = 1 implemented only with psatd.update_with_rho = 1"); + } } void -- cgit v1.2.3