Acoustic FDTD Solver
ACFDTD22.hpp
Go to the documentation of this file.
1 #ifndef ACFDTD22_HPP
2 #define ACFDTD22_HPP
3 
4 #include "constant.hpp"
5 
6 #include "Model.hpp"
8 #include "ObservationRegion.hpp"
9 #include "PointSensor.hpp"
10 #include "LineSensor.hpp"
12 
17 class ACFDTD22 {
18 private:
19  unsigned short **bya, **byb, **bza, **bzb;
20  unsigned short **pra, **prb, **prc, **prd, **pre;
21  unsigned short **aya, **ayb, **aza, **azb;
22  unsigned short **uya, **uyb, **uyc, **uza, **uzb, **uzc;
23 
27  void parseModel(const Model &model, const Grid &grid);
28 
29 protected:
31  std::string sim_name;
32  double f_c;
33  double S;
34  double dt;
35  unsigned nTimeSteps;
37 public:
38  ACFDTD22();
39 
40  ACFDTD22(const double frequency, const double cfl_number);
41 
49  virtual void calcCoefficients(const Model &model, const Grid &grid);
50 
55  virtual void execute(const Grid &grid,
56  const CartPosition &sig_loc,
57  const Function *signal,
58  const double time_span,
59  const std::vector<Sensor *> &sen_vec,
60  const unsigned negY=BC_PRESS,
61  const unsigned posY=BC_PRESS,
62  const unsigned negZ=BC_PRESS,
63  const unsigned posZ=BC_PRESS);
64 
83  virtual void execute(const Model &model,
84  const Grid &grid,
85  const HardPlaneWaveSource &source,
86  const double time_span,
87  const std::vector<Sensor *> &sen_vec,
88  const unsigned negY=BC_PRESS,
89  const unsigned posY=BC_PRESS,
90  const unsigned negZ=BC_PRESS,
91  const unsigned posZ=BC_PRESS);
92 
93  virtual double getDeltaT() const ;
94  virtual unsigned getnTimeSteps() const;
95  virtual ~ACFDTD22();
96 };
97 
98 
99 
100 #endif