class Window : public Pipe

Windowing base class.

Inheritance:


Public Methods

Window(void)
Default constructor.
virtual ~Window()
Virtual destructor.
TSeries apply(const TSeries& ts)
Return a windowed TSeries.
TSeries operator)(const TSeries& ts)
Return a windowed TSeries.
void dataCheck(const TSeries& ts) const
Check the data for validity
bool isDataValid(const TSeries& ts) const
Check the data for validity
double getRMS(void)
Get window function RMS.
void setWindow(int N)
Set the length and calculate the Window function.
virtual double WinFc(double arg)
Calculate the Window function.
virtual bool isPiSymmetric(void)
Test the Window function for symmetry around .

Inherited from Pipe:

Public Methods

virtual void reset(void)
virtual bool inUse(void) const
KeyChain& getInputKeys(void) const
KeyChain& getOutputKeys(void) const
virtual Time getStartTime(void) const
virtual Time getCurrentTime(void) const

Inherited from FilterBase:

Public Methods

virtual bool rootGetStartTime(Time& t) const throw()
virtual bool rootGetCurrentTime(Time& t) const throw()

Documentation

The Window base class performs all the common window calculation operations. The derived classes typically differ from one another only in the window function and the constructors needed to provide whatever variation is appropriate to the specific window type. The Window base class forces a normalization of . This maintains the power of a windowed series approximately constant, but it overrides any normalization built into the window function.

The Window function calculation can save half of the computation steps for Windows that are symmetric about the center bin (). This symmetry is assumed by default. Derived classes representing windows that don't exhibit this symmetry should define isPiSymmetric() to return false.

Window(void)
Build an empty window function.

virtual ~Window()
Destroy the Window object and release the function storage.

TSeries apply(const TSeries& ts)
The argument time series is multiplied on an element-by-element basis by the windowing function. The resulting windowed series is returned. The argument TSeries is left unchanged. The Window normalization is set to , as described in the class description.

TSeries operator)(const TSeries& ts)
The argument time series is multiplied on an element-by-element basis by the windowing function. The resulting windowed series is returned. The argument TSeries is left unchanged. The Window normalization is set to , as described in the class description.

void dataCheck(const TSeries& ts) const
Check the data for validity. If the data are not applicable for this window, an exception is thrown.

bool isDataValid(const TSeries& ts) const
Check the data for validity. Performs the same data checks as dataCheck() but returns a boolean status instead f throwing an exception.

double getRMS(void)
Get window function RMS.

void setWindow(int N)
The Window table length is set to the specified value. A new function array is allocated if insufficient storage is available. The function array is then filled with the calculated window coefficients.
Parameters:
N - Number of entries in the current window function table.

virtual double WinFc(double arg)
The window function is calculated at the argument position (, n is the entry number, N is the total number of entries)

virtual bool isPiSymmetric(void)
Return true if the Window function is symmetric around . Functions are by default symmetric, but the symmetry assumption may be preempted by defining isPiSymmetric() for a derived class.
Returns:
true if the window function is symmetric around .


Direct child classes:
Hanning
Hamming
FlatTop
Blackman
Author:
John G. Zweizig
Version:
1.1 ; Modified July 21, 1999

alphabetic index hierarchy of classes


generated by doc++