aboutsummaryrefslogtreecommitdiff
path: root/Source/Diagnostics/FullDiagnostics.H
diff options
context:
space:
mode:
authorGravatar Roelof Groenewald <40245517+roelof-groenewald@users.noreply.github.com> 2023-08-20 14:26:37 -0700
committerGravatar GitHub <noreply@github.com> 2023-08-20 14:26:37 -0700
commit5b74a61c631102a1c121a3668d0c02098c259b9b (patch)
tree818d73a3b4b75cf191b51e0bdb581b145d63b0eb /Source/Diagnostics/FullDiagnostics.H
parent9ce0b9c2cbd8f4881347a3f0d5a6cbf04c7a7919 (diff)
downloadWarpX-5b74a61c631102a1c121a3668d0c02098c259b9b.tar.gz
WarpX-5b74a61c631102a1c121a3668d0c02098c259b9b.tar.zst
WarpX-5b74a61c631102a1c121a3668d0c02098c259b9b.zip
Include `J` in diagnostic output when an electromagnetic solver is not used (#4116)
* include current density in diagnostic output even if an electromagnetic solver is not used * do not redeposit current for the magnetostatic solver * update CI benchmarks for tests that previously did not register current density * fix remaining failing CI test * Apply suggestions from code review Co-authored-by: Edoardo Zoni <59625522+EZoni@users.noreply.github.com> * do not output current density in collision tests * update `JFunctor` constructor doc-string * code cleanup - reduce code duplication * specify `Ex Ey Ez Bx By Bz` fields to plot for collision CI tests * specify `Er Et Ez Br Bt Bz` as output for rz collision test * rename `InterpolateToDst` to `InterpolateMFForDiag` * only deposit current density once per diagnostic output (if not already deposited) * write deposited current for all directions into `current_fp` during diagnostic step deposition * use `amrex::make_alias` to directly deposit current density into `warpx.current_fp` during diagnostic step deposition * add class variable `solver_deposits_current` to `FullDiagnostics` so that there is only one place where the determination is made whether current should be deposited during diagnostic output * correct logic to determine `m_solver_deposits_current` --------- Co-authored-by: Edoardo Zoni <59625522+EZoni@users.noreply.github.com>
Diffstat (limited to 'Source/Diagnostics/FullDiagnostics.H')
-rw-r--r--Source/Diagnostics/FullDiagnostics.H4
1 files changed, 4 insertions, 0 deletions
diff --git a/Source/Diagnostics/FullDiagnostics.H b/Source/Diagnostics/FullDiagnostics.H
index a20b44397..4bb3e2789 100644
--- a/Source/Diagnostics/FullDiagnostics.H
+++ b/Source/Diagnostics/FullDiagnostics.H
@@ -22,6 +22,10 @@ private:
bool m_plot_raw_fields_guards = false;
/** Whether to dump the RZ modes */
bool m_dump_rz_modes = false;
+ /** Whether the field solver deposits current density, if not it will be done
+ * before writing the diagnostic.
+ */
+ bool m_solver_deposits_current = true;
/** Flush m_mf_output and particles to file for the i^th buffer */
void Flush (int i_buffer) override;
/** Flush raw data */