itpp_sci  1.0.0
it++ based simulation framework for scicoslab, scilab and scipy
sim_amp.hpp
1 /*xxx
2  * \brief - SIM::amp - gain block
3  * \author maki
4  */
5 
6 
7 #ifndef SIM_AMP_HPP
8 #define SIM_AMP_HPP
9 
10 #include <itpp/itbase.h>
11 
12 using namespace itpp;
13 using namespace std;
14 
15 namespace SIM
16 {
17 
27 class amp
28 {
29  double y0;
30  double gain;
31  double offset;
32 
33 public:
34 
35  amp()
36  {
37  y0 = 0.0;
38  gain = 1.0;
39  offset = 0.0;
40  };
41 
42  ~amp()
43  {
44  };
45 
49  void set_gain(double g);
50 
54  void set_offset(double o);
55 
59  void set_output(double yout);
60 
64  double get_gain(void);
65 
69  double get_offset(void);
70 
74  double get_output(void);
75 
81  vec process(const bvec &ce, const vec &x);
82 };
83 
84 } // namespace SIM
85 #endif //SIM_AMP_HPP
86 
~amp()
Definition: sim_amp.hpp:42
amp()
Definition: sim_amp.hpp:35
SIM layer implements low level simulation models with itpp base classes as operational types...
Definition: sim_amp.hpp:15
gain block with offset Core function SIM::amp.process()
Definition: sim_amp.hpp:27
Definition: _sci_assert.cpp:35