blob: ec16d8184c5ad30300bc8cdaef72f73c2046be1b (
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
|
/* Copyright 2019-2020
*
* This file is part of WarpX.
*
* License: BSD-3-Clause-LBNL
*/
#ifndef WARPX_DIAGNOSTICS_REDUCEDDIAGS_PARTICLEMOMENTUM_H_
#define WARPX_DIAGNOSTICS_REDUCEDDIAGS_PARTICLEMOMENTUM_H_
#include "ReducedDiags.H"
#include <string>
/**
* \brief This class mainly contains a function that computes
* the particle relativistic momentum of each species.
*/
class ParticleMomentum : public ReducedDiags
{
public:
/**
* \brief Constructor
*
* \param[in] rd_name reduced diags names
*/
ParticleMomentum(std::string rd_name);
/**
* \brief This function computes the particle relativistic momentum,
* obtained by summing over all particles the product p * w,
* where p is the relativistic momentum and w is the individual particle weight.
*
* \param [in] step current time step
*/
virtual void ComputeDiags(int step) override final;
};
#endif
|