Revision 33, 1.0 kB
(checked in by smidl, 16 years ago)
|
Oprava PF a MPF + jejich implementace pro pmsm system
|
-
Property svn:eol-style set to
native
|
Line | |
---|
1 | /*! |
---|
2 | \file |
---|
3 | \brief Common DataSources. |
---|
4 | \author Vaclav Smidl. |
---|
5 | |
---|
6 | ----------------------------------- |
---|
7 | BDM++ - C++ library for Bayesian Decision Making under Uncertainty |
---|
8 | |
---|
9 | Using IT++ for numerical operations |
---|
10 | ----------------------------------- |
---|
11 | */ |
---|
12 | |
---|
13 | #ifndef DS_H |
---|
14 | #define DS_H |
---|
15 | |
---|
16 | #include <itpp/itbase.h> |
---|
17 | #include "libBM.h" |
---|
18 | |
---|
19 | using namespace itpp; |
---|
20 | |
---|
21 | /*! |
---|
22 | * \brief Class representing off-line data stored in memory |
---|
23 | |
---|
24 | The data are stored in an internal matrix \c Data . Each column of Data corresponds to one discrete time observation $t$. Access to this matrix is via indexes \c rowid and \c delays. |
---|
25 | |
---|
26 | The data can be loaded from a file. |
---|
27 | */ |
---|
28 | class MemDS : public DS { |
---|
29 | mat Data; |
---|
30 | int time; |
---|
31 | ivec rowid; |
---|
32 | ivec delays; |
---|
33 | |
---|
34 | public: |
---|
35 | void getdata(vec &dt); |
---|
36 | void getdata(vec &dt, ivec &indeces); |
---|
37 | void linkrvs(RV &drv, RV &urv); |
---|
38 | void write(vec &ut){it_error("MemDS::write is not supported");} |
---|
39 | void write(vec &ut,ivec &indexes){it_error("MemDS::write is not supported");} |
---|
40 | void step(); |
---|
41 | //!Default constructor |
---|
42 | MemDS(mat &Dat, ivec &rowid, ivec &delays); |
---|
43 | }; |
---|
44 | |
---|
45 | |
---|
46 | |
---|
47 | #endif // DS_H |
---|