aboutsummaryrefslogtreecommitdiff
path: root/Source/Utils/WarpXAlgorithmSelection.H
diff options
context:
space:
mode:
authorGravatar MaxThevenet <mthevenet@lbl.gov> 2019-06-18 14:03:14 -0700
committerGravatar MaxThevenet <mthevenet@lbl.gov> 2019-06-18 14:03:14 -0700
commit2628876d44bbd67c17ecb8a8db61a36aea36fad0 (patch)
tree668dcf8ed4208f310021f6023c9c055a9cc3f81d /Source/Utils/WarpXAlgorithmSelection.H
parent828b516cd72d0e8cd0dd0225a2fde12aeee8dbff (diff)
parent89df8eb11ed61bd6d6f58a2e096b1eb3a132538a (diff)
downloadWarpX-2628876d44bbd67c17ecb8a8db61a36aea36fad0.tar.gz
WarpX-2628876d44bbd67c17ecb8a8db61a36aea36fad0.tar.zst
WarpX-2628876d44bbd67c17ecb8a8db61a36aea36fad0.zip
Merge branch 'dev' into update_perftest
Diffstat (limited to 'Source/Utils/WarpXAlgorithmSelection.H')
-rw-r--r--Source/Utils/WarpXAlgorithmSelection.H57
1 files changed, 57 insertions, 0 deletions
diff --git a/Source/Utils/WarpXAlgorithmSelection.H b/Source/Utils/WarpXAlgorithmSelection.H
new file mode 100644
index 000000000..3fb23698a
--- /dev/null
+++ b/Source/Utils/WarpXAlgorithmSelection.H
@@ -0,0 +1,57 @@
+#ifndef UTILS_WARPXALGORITHMSELECTION_H_
+#define UTILS_WARPXALGORITHMSELECTION_H_
+
+#include <AMReX_ParmParse.H>
+#include <string>
+
+struct MaxwellSolverAlgo {
+ // These numbers corresponds to the algorithm code in WarpX's
+ // `warpx_push_bvec` and `warpx_push_evec_f`
+ enum {
+ Yee = 0,
+ CKC = 1
+ };
+};
+
+struct ParticlePusherAlgo {
+ // These numbers correspond to the algorithm code in WarpX's
+ // `warpx_particle_pusher`
+ enum {
+ Boris = 0,
+ Vay = 1
+ };
+};
+
+struct CurrentDepositionAlgo {
+ enum {
+ // These numbers corresponds to the algorithm code in PICSAR's
+ // `depose_jxjyjz_generic` and `depose_jxjyjz_generic_2d`
+ Direct = 3,
+ DirectVectorized = 2,
+ EsirkepovNonOptimized = 1,
+ Esirkepov = 0
+ };
+};
+
+struct ChargeDepositionAlgo {
+ // These numbers corresponds to the algorithm code in WarpX's
+ // `warpx_charge_deposition` function
+ enum {
+ Vectorized = 0,
+ Standard = 1
+ };
+};
+
+struct GatheringAlgo {
+ // These numbers corresponds to the algorithm code in PICSAR's
+ // `geteb3d_energy_conserving_generic` function
+ enum {
+ Vectorized = 0,
+ Standard = 1
+ };
+};
+
+int
+GetAlgorithmInteger( amrex::ParmParse& pp, const char* pp_search_key );
+
+#endif // UTILS_WARPXALGORITHMSELECTION_H_