aboutsummaryrefslogtreecommitdiff
path: root/Source/Utils
diff options
context:
space:
mode:
Diffstat (limited to 'Source/Utils')
-rw-r--r--Source/Utils/WarpXAlgorithmSelection.H4
-rw-r--r--Source/Utils/WarpXAlgorithmSelection.cpp5
-rw-r--r--Source/Utils/WarpXTagging.cpp6
3 files changed, 8 insertions, 7 deletions
diff --git a/Source/Utils/WarpXAlgorithmSelection.H b/Source/Utils/WarpXAlgorithmSelection.H
index 269171a5f..7d26e7af5 100644
--- a/Source/Utils/WarpXAlgorithmSelection.H
+++ b/Source/Utils/WarpXAlgorithmSelection.H
@@ -34,9 +34,9 @@ struct ChargeDepositionAlgo {
};
struct GatheringAlgo {
- // Only the Standard algorithm is implemented
enum {
- Standard = 0
+ EnergyConserving = 0,
+ MomentumConserving
};
};
diff --git a/Source/Utils/WarpXAlgorithmSelection.cpp b/Source/Utils/WarpXAlgorithmSelection.cpp
index be9cdd118..4b66a0809 100644
--- a/Source/Utils/WarpXAlgorithmSelection.cpp
+++ b/Source/Utils/WarpXAlgorithmSelection.cpp
@@ -34,8 +34,9 @@ const std::map<std::string, int> charge_deposition_algo_to_int = {
};
const std::map<std::string, int> gathering_algo_to_int = {
- {"standard", GatheringAlgo::Standard },
- {"default", GatheringAlgo::Standard }
+ {"energy-conserving", GatheringAlgo::EnergyConserving },
+ {"momentum-conserving", GatheringAlgo::MomentumConserving },
+ {"default", GatheringAlgo::EnergyConserving }
};
diff --git a/Source/Utils/WarpXTagging.cpp b/Source/Utils/WarpXTagging.cpp
index 8ea3211a3..91bb802e8 100644
--- a/Source/Utils/WarpXTagging.cpp
+++ b/Source/Utils/WarpXTagging.cpp
@@ -22,9 +22,9 @@ WarpX::ErrorEst (int lev, TagBoxArray& tags, Real time, int /*ngrow*/)
for (BoxIterator bi(bx); bi.ok(); ++bi)
{
const IntVect& cell = bi();
- RealVect pos {AMREX_D_DECL((cell[0]+0.5)*dx[0]+problo[0],
- (cell[1]+0.5)*dx[1]+problo[1],
- (cell[2]+0.5)*dx[2]+problo[2])};
+ RealVect pos {AMREX_D_DECL((cell[0]+0.5_rt)*dx[0]+problo[0],
+ (cell[1]+0.5_rt)*dx[1]+problo[1],
+ (cell[2]+0.5_rt)*dx[2]+problo[2])};
if (pos > fine_tag_lo && pos < fine_tag_hi) {
fab(cell) = TagBox::SET;
}