VAPOR3 3.9.4
MatWaveBase.h
Go to the documentation of this file.
1#ifndef _MatWaveBase_h_
2#define _MatWaveBase_h_
3
4#include <string>
5#include "WaveFiltBase.h"
6
7using namespace std;
8
9namespace VAPoR {
10
11//
24public:
28 enum dwtmode_t { INVALID = -1, ZPD, SYMH, SYMW, ASYMH, ASYMW, SP0, SP1, PPD, PER };
29
37 MatWaveBase(const string &wname, const string &mode);
38 MatWaveBase(const string &wname);
39 virtual ~MatWaveBase();
40
49 int dwtmode(const string &mode);
50
58 int dwtmode(dwtmode_t mode);
59
66 const string dwtmode() const;
67
72 dwtmode_t dwtmodeenum() const { return (_mode); };
73
82 int wavelet(const string &wname);
83
88 string wavelet_name() const { return (_wname); };
89
94 const WaveFiltBase *wavelet() const { return (_wf); };
95
108 //
109 size_t approxlength(size_t sigInLen) const;
110
122 //
123 size_t detaillength(size_t sigInLen) const;
124
135 //
136 size_t coefflength(size_t sigInLen) const { return (approxlength(sigInLen) + detaillength(sigInLen)); };
137
138 size_t coefflength2(size_t sigInX, size_t sigInY) const { return (coefflength(sigInX) * coefflength(sigInY)); };
139
140 size_t coefflength3(size_t sigInX, size_t sigInY, size_t sigInZ) const { return (coefflength(sigInX) * coefflength(sigInY) * coefflength(sigInZ)); };
141
154 //
155 size_t wmaxlev(size_t s) const;
156
165 //
166 bool &InvalidFloatAbortOnOff() { return (_InvalidFloatAbort); };
167
168protected:
169private:
170 bool _InvalidFloatAbort;
171 dwtmode_t _mode;
172 WaveFiltBase *_wf;
173 string _wname;
174
175 WaveFiltBase *_create_wf(const string &wname) const;
176
177 void _wave_len_validate(size_t sigInLen, int waveLength, size_t *lev, size_t *val) const;
178
179 dwtmode_t _dwtmodestr2enum(const string &mode) const;
180 string _dwtmodeenum2str(dwtmode_t mode) const;
181};
182
183} // namespace VAPoR
184
185#endif
A base class for a Matlab-like wavelet bank.
Definition: MatWaveBase.h:23
int dwtmode(dwtmode_t mode)
string wavelet_name() const
Definition: MatWaveBase.h:88
size_t detaillength(size_t sigInLen) const
const string dwtmode() const
size_t wmaxlev(size_t s) const
virtual ~MatWaveBase()
MatWaveBase(const string &wname)
size_t coefflength2(size_t sigInX, size_t sigInY) const
Definition: MatWaveBase.h:138
bool & InvalidFloatAbortOnOff()
Definition: MatWaveBase.h:166
const WaveFiltBase * wavelet() const
Definition: MatWaveBase.h:94
MatWaveBase(const string &wname, const string &mode)
size_t coefflength3(size_t sigInX, size_t sigInY, size_t sigInZ) const
Definition: MatWaveBase.h:140
int wavelet(const string &wname)
dwtmode_t dwtmodeenum() const
Definition: MatWaveBase.h:72
size_t approxlength(size_t sigInLen) const
int dwtmode(const string &mode)
size_t coefflength(size_t sigInLen) const
Definition: MatWaveBase.h:136
A base class for wavelet family filters.
Definition: WaveFiltBase.h:21
Wasp base class.
Definition: MyBase.h:67
#define WASP_API
Definition: common.h:74