WarpX
Public Member Functions | Private Attributes | List of all members
ChargeOnEB Class Reference

#include <ChargeOnEB.H>

Inheritance diagram for ChargeOnEB:
ReducedDiags

Public Member Functions

 ChargeOnEB (const std::string &rd_name)
 
void ComputeDiags (int step) final
 
- Public Member Functions inherited from ReducedDiags
 ReducedDiags (const std::string &rd_name)
 
virtual ~ReducedDiags ()=default
 
 ReducedDiags (const ReducedDiags &)=default
 
ReducedDiagsoperator= (const ReducedDiags &)=default
 
 ReducedDiags (ReducedDiags &&)=default
 
ReducedDiagsoperator= (ReducedDiags &&)=default
 
virtual void InitData ()
 
virtual void LoadBalance ()
 
virtual void WriteToFile (int step) const
 
void BackwardCompatibility () const
 

Private Attributes

std::unique_ptr< amrex::Parserm_parser_weighting
 Optional parser to add weight inside the integral. More...
 
bool m_do_parser_weighting = false
 Whether the weighting is activated. More...
 

Additional Inherited Members

- Public Attributes inherited from ReducedDiags
std::string m_path = "./diags/reducedfiles/"
 output path (default) More...
 
std::string m_extension = "txt"
 output extension (default) More...
 
std::string m_rd_name
 diags name More...
 
utils::parser::IntervalsParser m_intervals
 output intervals More...
 
bool m_write_header = false
 check if header should be written More...
 
std::string m_sep = " "
 separator in the output file More...
 
int m_precision = 14
 precision for data in the output file More...
 
std::vector< amrex::Real > m_data
 output data More...
 

Detailed Description

This class mainly contains a function that computes the total charge at the surface of the embedded boundary, by using the formula $Q_{tot} = \epsilon_0 \iint dS \cdot E$ where the integral is performed over the surface of the embedded boundary.

If a weighting function is provided, this computes $Q_{tot} = \epsilon_0 \iint dS \cdot E \times weighting(x, y, z)

Constructor & Destructor Documentation

◆ ChargeOnEB()

ChargeOnEB::ChargeOnEB ( const std::string &  rd_name)

constructor

Parameters
[in]rd_namereduced diags names

Member Function Documentation

◆ ComputeDiags()

void ChargeOnEB::ComputeDiags ( int  step)
finalvirtual

This function computes the charge at the surface of the EB: $Q_{tot} = \epsilon_0 \iint dS \cdot E$ where the integral is performed over the EB surface

Parameters
[in]stepcurrent time step

Implements ReducedDiags.

Member Data Documentation

◆ m_do_parser_weighting

bool ChargeOnEB::m_do_parser_weighting = false
private

Whether the weighting is activated.

◆ m_parser_weighting

std::unique_ptr<amrex::Parser> ChargeOnEB::m_parser_weighting
private

Optional parser to add weight inside the integral.


The documentation for this class was generated from the following files: