Marsyas  0.5.0-beta1
Public Member Functions
OnePole Class Reference

Simple one-pole digital filter. More...

#include <OnePole.h>

Inherits MarSystem.

Public Member Functions

MarSystemclone () const
void myProcess (realvec &in, realvec &out)
 Processes data.
 OnePole (std::string name)
 ~OnePole ()

Detailed Description

Simple one-pole digital filter.

OnePole implements the digital filter described by equation

\[ y(t) = (1 - \alpha) x(t) + \alpha y(t - 1) \]

This filter has one pole at $ z = \alpha $. If $ \alpha > 0 $, the filter has a low-pass characteristic, the closer to 1 the smaller the pass band. If $ \alpha < 0 $, it has a high-pass characteristic, the closer to -1, the smaller the pass band.

Note that the coefficient of $ x(t) $ is set to $ (1-\alpha) $ to have unity gain for the DC component (both in the low pass and high pass case) as a sort of normalization.


See also:

Definition at line 50 of file OnePole.h.

Constructor & Destructor Documentation

OnePole ( std::string  name)

Definition at line 25 of file OnePole.cpp.

~OnePole ( )

Definition at line 31 of file OnePole.cpp.

Member Function Documentation

MarSystem * clone ( ) const [virtual]

Implements MarSystem.

Definition at line 37 of file OnePole.cpp.

void myProcess ( realvec in,
realvec out 
) [virtual]

Processes data.

inInput data to read.
outOutput data to write.

Implement this method in subclass to define specific data processing.

Implements MarSystem.

Definition at line 67 of file OnePole.cpp.

The documentation for this class was generated from the following files: