diff options
author | 2021-10-04 09:45:58 -0700 | |
---|---|---|
committer | 2021-10-04 09:45:58 -0700 | |
commit | 95bb2598047300aa1a62d47b0cb23de172df4b77 (patch) | |
tree | 987ba76893e86ca66d52cc24bd471ad836734896 /Source/Particles/MultiParticleContainer.cpp | |
parent | 876c994835524dacacc8bd05bced68fc45ecef0f (diff) | |
download | WarpX-95bb2598047300aa1a62d47b0cb23de172df4b77.tar.gz WarpX-95bb2598047300aa1a62d47b0cb23de172df4b77.tar.zst WarpX-95bb2598047300aa1a62d47b0cb23de172df4b77.zip |
Implement Checkpoint / Restart for Laser Particles (#2360)
* Initialize lasers when restarting + recalculate z position at each iteration
* Fix restart for rigid-injected particles
* Fix laser injection box at restart
* Use correct positions for the moving window of the BTD
* implement restart for laser particles
* add CI test for laser acceleration restarting
* writespace
* Revert "Fix restart for rigid-injected particles"
This reverts commit 33bf3a60126539b9566ead3115ff2bcdf4b80516.
* don't add lasers to all full diags, only checkpoints
* fix unused parameter warning
* move the call to reset the m_laser_injection_box into PostRestart
* bugfix for non-boosted frame simulations
* Read the mean velocity of the injected species
* Remove unused line
* Revert "Initialize lasers when restarting + recalculate z position at each iteration"
This reverts commit 322634c35aa996649d0e8fff9fb683d04f2ee121.
* Add new ReadHeader / WriteHeader functions
* Add WriteHeader/ReadHeader for laser particles
* Revert "add CI test for laser acceleration restarting"
This reverts commit 6ba0fb3c121027eecf8b5845f55080e5b187375d.
* Fix merge commit
* Correct reading of updated position
* Add laser in restart test
* Remove unused parameters
* Update regression tests
* Add benchmark files
* Update boundary conditions for restart_psatd
Co-authored-by: Remi Lehe <remi.lehe@normalesup.org>
Diffstat (limited to 'Source/Particles/MultiParticleContainer.cpp')
-rw-r--r-- | Source/Particles/MultiParticleContainer.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Source/Particles/MultiParticleContainer.cpp b/Source/Particles/MultiParticleContainer.cpp index 3868442c5..3f916c92a 100644 --- a/Source/Particles/MultiParticleContainer.cpp +++ b/Source/Particles/MultiParticleContainer.cpp @@ -834,13 +834,14 @@ MultiParticleContainer::mapSpeciesProduct () int MultiParticleContainer::getSpeciesID (std::string product_str) const { + auto species_and_lasers_names = GetSpeciesAndLasersNames(); int i_product = 0; bool found = 0; // Loop over species - for (int i=0; i < static_cast<int>(species_names.size()); i++){ + for (int i=0; i < static_cast<int>(species_and_lasers_names.size()); i++){ // If species name matches, store its ID // into i_product - if (species_names[i] == product_str){ + if (species_and_lasers_names[i] == product_str){ found = 1; i_product = i; } |