OPAL (Object Oriented Parallel Accelerator Library)  2021.1.99
OPAL
FM3DDynamic.h
Go to the documentation of this file.
1 #ifndef CLASSIC_FIELDMAP3DDYNAMIC_HH
2 #define CLASSIC_FIELDMAP3DDYNAMIC_HH
3 
4 #include "Fields/Fieldmap.h"
5 
6 class FM3DDynamic: public Fieldmap {
7 
8 public:
9  virtual bool getFieldstrength(const Vector_t &R, Vector_t &E, Vector_t &B) const;
10  virtual void getFieldDimensions(double &zBegin, double &zEnd) const;
11  virtual void getFieldDimensions(double &xIni, double &xFinal, double &yIni, double &yFinal, double &zIni, double &zFinal) const;
12  virtual bool getFieldDerivative(const Vector_t &R, Vector_t &E, Vector_t &B, const DiffDirection &dir) const;
13  virtual void swap();
14  virtual void getInfo(Inform *msg);
15  virtual double getFrequency() const;
16  virtual void setFrequency(double freq);
17  virtual void getOnaxisEz(std::vector<std::pair<double, double> > & F);
18 
19  virtual bool isInside(const Vector_t &r) const;
20 private:
21  FM3DDynamic(std::string aFilename);
22  ~FM3DDynamic();
23 
24  virtual void readMap();
25  virtual void freeMap();
26 
34  double frequency_m;
35 
36  double xbegin_m;
37  double xend_m;
38 
39  double ybegin_m;
40  double yend_m;
41 
42  double zbegin_m;
43  double zend_m;
44 
45  double hx_m;
46  double hy_m;
47  double hz_m;
48  unsigned int num_gridpx_m;
49  unsigned int num_gridpy_m;
50  unsigned int num_gridpz_m;
53  friend class Fieldmap;
54 };
55 
56 inline bool FM3DDynamic::isInside(const Vector_t &r) const
57 {
58  return ((r(0) >= xbegin_m && r(0) < xend_m) &&
59  (r(1) >= ybegin_m && r(1) < yend_m) &&
60  (r(2) >= zbegin_m && r(2) < zend_m));
61 }
62 
63 #endif
DiffDirection
Definition: Fieldmap.h:54
virtual void getInfo(Inform *msg)
double * FieldstrengthEx_m
Definition: FM3DDynamic.h:28
double hy_m
Definition: FM3DDynamic.h:46
double * FieldstrengthBx_m
Definition: FM3DDynamic.h:31
double xend_m
Definition: FM3DDynamic.h:37
unsigned int num_gridpz_m
Definition: FM3DDynamic.h:50
double zbegin_m
Definition: FM3DDynamic.h:42
unsigned int num_gridpy_m
Definition: FM3DDynamic.h:49
double frequency_m
Definition: FM3DDynamic.h:34
double * FieldstrengthEz_m
Definition: FM3DDynamic.h:27
double ybegin_m
Definition: FM3DDynamic.h:39
unsigned int num_gridpx_m
Definition: FM3DDynamic.h:48
double zend_m
Definition: FM3DDynamic.h:43
bool normalize_m
Definition: FM3DDynamic.h:52
virtual void swap()
virtual void getOnaxisEz(std::vector< std::pair< double, double > > &F)
virtual void freeMap()
virtual bool getFieldstrength(const Vector_t &R, Vector_t &E, Vector_t &B) const
double * FieldstrengthBy_m
Definition: FM3DDynamic.h:32
virtual void setFrequency(double freq)
FM3DDynamic(std::string aFilename)
Definition: FM3DDynamic.cpp:14
virtual void readMap()
double hx_m
Definition: FM3DDynamic.h:45
double xbegin_m
Definition: FM3DDynamic.h:36
double * FieldstrengthBz_m
Definition: FM3DDynamic.h:30
virtual void getFieldDimensions(double &zBegin, double &zEnd) const
double yend_m
Definition: FM3DDynamic.h:40
virtual bool getFieldDerivative(const Vector_t &R, Vector_t &E, Vector_t &B, const DiffDirection &dir) const
virtual double getFrequency() const
virtual bool isInside(const Vector_t &r) const
Definition: FM3DDynamic.h:56
double hz_m
Definition: FM3DDynamic.h:47
double * FieldstrengthEy_m
Definition: FM3DDynamic.h:29
Definition: Inform.h:42