diff options
author | 2019-10-08 15:23:04 -0700 | |
---|---|---|
committer | 2019-10-08 15:23:04 -0700 | |
commit | 34bd7c7634d59bde4f978d618e788b2316d3d771 (patch) | |
tree | e014e222e399d5385c58ab001486f747ee1383a3 /Source/Evolve/WarpXEvolveEM.cpp | |
parent | f8a87298908e2310d53cbc0c3215613f1b1606b2 (diff) | |
parent | e5689e27f15466975dcbbe9754394ee4b45d91e3 (diff) | |
download | WarpX-34bd7c7634d59bde4f978d618e788b2316d3d771.tar.gz WarpX-34bd7c7634d59bde4f978d618e788b2316d3d771.tar.zst WarpX-34bd7c7634d59bde4f978d618e788b2316d3d771.zip |
Merge pull request #448 from MaxThevenet/compute_step_lab
[mini-PR] allow warpx.zmax_plasma_to_compute_max_step = ... in lab frame
Diffstat (limited to 'Source/Evolve/WarpXEvolveEM.cpp')
-rw-r--r-- | Source/Evolve/WarpXEvolveEM.cpp | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/Source/Evolve/WarpXEvolveEM.cpp b/Source/Evolve/WarpXEvolveEM.cpp index 1e4aa4d5c..7a3262703 100644 --- a/Source/Evolve/WarpXEvolveEM.cpp +++ b/Source/Evolve/WarpXEvolveEM.cpp @@ -590,13 +590,14 @@ WarpX::computeMaxStepBoostAccelerator(amrex::Geometry a_geom){ WarpX::moving_window_dir == AMREX_SPACEDIM-1, "Can use zmax_plasma_to_compute_max_step only if " + "moving window along z. TODO: all directions."); - - AMREX_ALWAYS_ASSERT_WITH_MESSAGE( - (WarpX::boost_direction[0]-0)*(WarpX::boost_direction[0]-0) + - (WarpX::boost_direction[1]-0)*(WarpX::boost_direction[1]-0) + - (WarpX::boost_direction[2]-1)*(WarpX::boost_direction[2]-1) < 1.e-12, - "Can use zmax_plasma_to_compute_max_step only if " + - "warpx.boost_direction = z. TODO: all directions."); + if (gamma_boost > 1){ + AMREX_ALWAYS_ASSERT_WITH_MESSAGE( + (WarpX::boost_direction[0]-0)*(WarpX::boost_direction[0]-0) + + (WarpX::boost_direction[1]-0)*(WarpX::boost_direction[1]-0) + + (WarpX::boost_direction[2]-1)*(WarpX::boost_direction[2]-1) < 1.e-12, + "Can use zmax_plasma_to_compute_max_step in boosted frame only if " + + "warpx.boost_direction = z. TODO: all directions."); + } // Lower end of the simulation domain. All quantities are given in boosted // frame except zmax_plasma_to_compute_max_step. |