1#ifndef G_COMPONENT_CONSTANT_H
2#define G_COMPONENT_CONSTANT_H
17 void ElectricField(
const double x,
const double y,
const double z,
double& ex,
18 double& ey,
double& ez,
Medium*& m,
int& status)
override;
19 void ElectricField(
const double x,
const double y,
const double z,
double& ex,
20 double& ey,
double& ez,
double& v,
Medium*& m,
21 int& status)
override;
23 void WeightingField(
const double x,
const double y,
const double z,
24 double& wx,
double& wy,
double& wz,
25 const std::string& label)
override;
27 const std::string& label)
override;
32 void SetPotential(
const double x,
const double y,
const double z,
37 const std::string label);
49 bool m_hasPotential =
false;
51 double m_x0 = 0., m_y0 = 0., m_z0 = 0.;
56 bool m_hasWeightingField =
false;
57 std::string m_wfield =
"";
58 double m_fwx = 0., m_fwy = 0., m_fwz = 0.;
59 bool m_hasWeightingPotential =
false;
61 double m_wx0 = 0., m_wy0 = 0., m_wz0 = 0.;
65 void Reset()
override;
66 void UpdatePeriodicity()
override;
Abstract base class for components.
Component with constant electric field.
double WeightingPotential(const double x, const double y, const double z, const std::string &label) override
bool GetVoltageRange(double &vmin, double &vmax) override
Calculate the voltage range [V].
void ElectricField(const double x, const double y, const double z, double &ex, double &ey, double &ez, Medium *&m, int &status) override
~ComponentConstant()
Destructor.
void SetElectricField(const double ex, const double ey, const double ez)
Set the components of the electric field [V / cm].
void WeightingField(const double x, const double y, const double z, double &wx, double &wy, double &wz, const std::string &label) override
void SetPotential(const double x, const double y, const double z, const double v=0.)
Specify the potential at a given point.
void SetWeightingPotential(const double x, const double y, const double z, const double v=0.)
Specify the weighting potential at a given point.
void SetWeightingField(const double wx, const double wy, const double wz, const std::string label)
Set the components of the weighting field [1 / cm].
ComponentConstant()
Constructor.
Abstract base class for media.