blob: e7386f7338354957003727286252d38bf52f4c78 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
/* Copyright 2020 Neil Zaim
*
* This file is part of WarpX.
*
* License: BSD-3-Clause-LBNL
*/
#ifndef WARPX_DIAGNOSTICS_REDUCEDDIAGS_RHOMAXIMUM_H_
#define WARPX_DIAGNOSTICS_REDUCEDDIAGS_RHOMAXIMUM_H_
#include "Diagnostics/ComputeDiagFunctors/ComputeDiagFunctor.H"
#include "ReducedDiags.H"
#include <AMReX_Vector.H>
#include <memory>
#include <string>
/**
* This class mainly contains a function that computes the extrema of the total charge density
* and of the charge density of each charged species.
*/
class RhoMaximum : public ReducedDiags
{
public:
/**
* constructor
* @param[in] rd_name reduced diags names
*/
RhoMaximum(std::string rd_name);
/**
* This function computes the maximum and minimum values of rho (summed over all species) and
* the maximum absolute value of rho for each species.
*
* @param[in] step current time step
*/
virtual void ComputeDiags(int step) override final;
private:
/** Vector of (pointers to) functors to compute rho, per level, per species. We reuse here the
* same functors as those used for regular diagnostics.
* */
amrex::Vector< amrex::Vector <std::unique_ptr<ComputeDiagFunctor > > > m_rho_functors;
};
#endif // WARPX_DIAGNOSTICS_REDUCEDDIAGS_RHOMAXIMUM_H_
|