Skip to content

Commit c734171

Browse files
committed
RZ: x,y,z
1 parent 2075825 commit c734171

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

Source/Diagnostics/ParticleDiag/ParticleDiag.cpp

+5-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,11 @@ ParticleDiag::ParticleDiag (
3636
std::fill(m_plot_flags.begin(), m_plot_flags.end(), 0);
3737
bool contains_positions = false;
3838
if (variables[0] != "none"){
39-
const std::map<std::string, int> existing_variable_names = pc->getParticleComps();
39+
std::map<std::string, int> existing_variable_names = pc->getParticleComps();
40+
#ifdef WARPX_DIM_RZ
41+
// we reconstruct to Cartesian x,y,z for RZ particle output
42+
existing_variable_names["y"] = PIdx::theta;
43+
#endif
4044
for (const auto& var : variables){
4145
if (var == "phi") {
4246
// User requests phi on particle. This is *not* part of the variables that

0 commit comments

Comments
 (0)