1#ifndef G_COMPONENT_USER_H
2#define G_COMPONENT_USER_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 MagneticField(
const double x,
const double y,
const double z,
double& bx,
24 double& by,
double& bz,
int& status)
override;
25 void WeightingField(
const double x,
const double y,
const double z,
26 double& wx,
double& wy,
double& wz,
27 const std::string& label)
override;
29 const std::string& label)
override;
31 const double t,
double& wx,
double& wy,
double& wz,
32 const std::string& label)
override;
36 double&,
double&,
double&));
38 void SetPotential(
void (*f)(
const double,
const double,
const double,
42 double&,
double&,
double&,
46 double&,
const std::string));
49 const double,
const double,
50 double&,
double&,
double&,
54 double&,
double&,
double&));
58 void (*m_efield)(
const double,
const double,
const double,
double&,
double&,
62 void (*m_potential)(
const double,
const double,
const double,
66 void (*m_wfield)(
const double,
const double,
const double,
double&,
double&,
67 double&,
const std::string) =
nullptr;
70 void (*m_wpot)(
const double,
const double,
const double,
double&,
71 const std::string) =
nullptr;
74 void (*m_dwfield)(
const double,
const double,
const double,
const double,
75 double&,
double&,
double&,
const std::string) =
nullptr;
78 void (*m_bfield)(
const double,
const double,
const double,
double&,
double&,
82 void Reset()
override;
84 void UpdatePeriodicity()
override;
Abstract base class for components.
Simple component with electric field given by a user function.
void SetWeightingField(void(*f)(const double, const double, const double, double &, double &, double &, const std::string))
Set the function to be called for calculating the weighting field.
void DelayedWeightingField(const double x, const double y, const double z, const double t, double &wx, double &wy, double &wz, const std::string &label) override
void SetMagneticField(void(*f)(const double, const double, const double, double &, double &, double &))
Set the function to be called for calculating the magnetic field.
double WeightingPotential(const double x, const double y, const double z, const std::string &label) override
void SetElectricField(void(*f)(const double, const double, const double, double &, double &, double &))
Set the function to be called for calculating the electric field.
void SetDelayedWeightingField(void(*f)(const double, const double, const double, const double, double &, double &, double &, const std::string))
Set the function to be called for calculating the delayed weighting field.
void WeightingField(const double x, const double y, const double z, double &wx, double &wy, double &wz, const std::string &label) override
ComponentUser()
Constructor.
void MagneticField(const double x, const double y, const double z, double &bx, double &by, double &bz, int &status) override
bool GetVoltageRange(double &vmin, double &vmax) override
Calculate the voltage range [V].
void SetPotential(void(*f)(const double, const double, const double, double &))
Set the function to be called for calculating the potential.
void ElectricField(const double x, const double y, const double z, double &ex, double &ey, double &ez, Medium *&m, int &status) override
void SetWeightingPotential(void(*f)(const double, const double, const double, double &, const std::string))
Set the function to be called for calculating the weighting potential.
~ComponentUser()
Destructor.
Abstract base class for media.