Field diagnostics plot. More...
#include <fielddiagplot.hpp>
Public Member Functions | |
FieldDiagPlot (Frame *frame, const Geometry *geom) | |
Constructor for field diagnostics plot. More... | |
~FieldDiagPlot () | |
Destructor for field diagnostics plot. More... | |
void | set_epot (const ScalarField *epot) |
Add pointer to electric potential. More... | |
void | set_efield (const VectorField *efield) |
Add pointer to electric field. More... | |
void | set_scharge (const ScalarField *scharge) |
Add pointer to space charge density map. More... | |
void | set_bfield (const VectorField *bfield) |
Add pointer to magnetic field. More... | |
void | set_coordinates (size_t N, const Vec3D &x1, const Vec3D &x2) |
Set coordinates for field diagnostics. More... | |
const Vec3D & | start (void) |
Get start coordinates of diagnostic line. More... | |
const Vec3D & | end (void) |
Get end coordinates of diagnostic line. More... | |
const size_t & | N (void) |
Get number of steps on diagnostic line. More... | |
void | set_diagnostic (const field_diag_type_e diag[2], const field_loc_type_e loc[2]) |
Set field and location plot types. More... | |
const field_diag_type_e & | get_diagnostic_type (int i) |
Get diagnostic type for y-axis i. More... | |
const field_loc_type_e & | get_location_type (int i) |
Get location type for x-axis i. More... | |
void | export_data (const std::string &filename) const |
Export plotted data as ASCII. More... | |
void | build_plot (void) |
Rebuild plot. More... | |
Field diagnostics plot.
A class for building xy-plots of various fields in simulations.
Constructor for field diagnostics plot.
FieldDiagPlot::~FieldDiagPlot | ( | ) |
Destructor for field diagnostics plot.
void FieldDiagPlot::build_plot | ( | void | ) |
Rebuild plot.
|
inline |
Get end coordinates of diagnostic line.
void FieldDiagPlot::export_data | ( | const std::string & | filename | ) | const |
Export plotted data as ASCII.
|
inline |
Get diagnostic type for y-axis i.
|
inline |
Get location type for x-axis i.
|
inline |
Get number of steps on diagnostic line.
|
inline |
Add pointer to magnetic field.
Set coordinates for field diagnostics.
The fields to be plotted are evaluated at N steps from x1 to x2. The first point of the plot is exactly at x1 and the last at x2.
|
inline |
Set field and location plot types.
The plot can have two x-axes and two y-axes. The diagnostic for y1-axis is set by diag[0] and the diagnostic for y2-axis by diag[1]. The x1-axis is defined by loc[0] and x2-axis by loc[1].
|
inline |
Add pointer to electric field.
|
inline |
Add pointer to electric potential.
|
inline |
Add pointer to space charge density map.
|
inline |
Get start coordinates of diagnostic line.