class Mixer : public Pipe

Mixer API

Inheritance:


Public Methods

Mixer(void)
Default constructor produces unitialized mixer object.
~Mixer(void)
Default destructor.
TSeries operator)(const TSeries& in)
Mix input TSeries with a local oscillator exp(2*pi*I*fc*t)
FilterIO& operator)(const FilterIO& in)
Mix input TSeries with a local oscillator exp(2*pi*I*fc*t)
TSeries apply(const TSeries& in)
Mix input TSeries with a local oscillator exp(2*pi*I*fc*t)
FilterIO& apply(const FilterIO& in)
Mix input TSeries with a local oscillator exp(2*pi*I*fc*t)
void dataCheck(const TSeries&) const
Validate filter input.
void dataCheck(const FilterIO&) const
Validate filter input without throwing exceptions.
void reset(void)
reset filter to a pristine state.
KeyChain& getInputKeys(void) const
Return a KeyChain with Keys for input TSeries. Currently unimplemented.
KeyChain& getOutputKeys(void) const
Return a KeyChain with Keys for output TSeries. Currently unimplemented.
Time getStartTime(void) const
Get the moment of the first sample processed.
Time getCurrentTime(void) const
Get the moment of the next expected sample.
float getPhase(void) const throw(std::range_error)
Get the current phase.
bool getPhase(float& phi) const throw()
Get the current phase.
float getFcHz(void) const throw(std::range_error, std::runtime_error)
Get the current phase.
bool getFcHz(float& fc) const throw()
Get the current phase. Root safe.
float getFcNyquist(void) const throw(std::range_error, std::runtime_error)
Get the current phase.
bool getFcNyquist(float& fc) const throw()
Get the current phase. Root-safe.
void setPhase(const float& phi) throw(std::logic_error)
Set the initial phase.
void setFcHz(const float& f) throw(std::logic_error)
Set the local oscillator frequency in Hz.
void setFcNyquist(const float& f) throw(std::logic_error)
Sets the local oscillator frequency in Nyquist frequency units.
bool inUse(void) const
Returns true if filter is in use.

Inherited from Pipe:

Public Methods

virtual bool isDataValid(const TSeries& in) const

Inherited from FilterBase:

Public Methods

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

Documentation

Mixer mixes a single input TSeries with a local oscillator, returning a single complex TSeries.
Mixer(void)
Default constructor produces uninitialized mixer object.

~Mixer(void)
Default destructor.

TSeries operator)(const TSeries& in)
Mix input TSeries with a local oscillator exp(2*pi*I*fc*t)
Parameters:
in - input TSeries

FilterIO& operator)(const FilterIO& in)
Mix input TSeries with a local oscillator exp(2*pi*I*fc*t)
Parameters:
in - container holding input TSeries

TSeries apply(const TSeries& in)
Mix input TSeries with a local oscillator exp(2*pi*I*fc*t)
Parameters:
in - input TSeries

FilterIO& apply(const FilterIO& in)
Mix input TSeries with a local oscillator exp(2*pi*I*fc*t)
Parameters:
in - container holding input TSeries

void dataCheck(const TSeries&) const
Validate filter input. The input TSeries is checked for continuity and consistency. Failure of either continuity or consistency throws a runtime_error exception.
Parameters:
in - TSeries to validate

void dataCheck(const FilterIO&) const
Validate filter input. The input container is checked to see that it has the correct type and that it is full. Failing either of these tests throws a logic_error exception. The contents of the container are checked for TSeries continuity and consistency. Failure of either continuity or consistency throws a runtime_error exception.
Parameters:
in - Container holding the input to validate

void reset(void)
Reset filter to a pristine state: local oscillator frequency, start time, current time, interval, and phase are all undefined and inUse() is false.

KeyChain& getInputKeys(void) const
Return a KeyChain for input TSeries. Use these keys to fill a FilterIO container with TSeries, optionally validates the container and contents with dataCheck(), and act on the input with apply().

KeyChain& getOutputKeys(void) const
Return a KeyChain for output TSeries. Use the keys on this chain to retrieve output TSeries from output FilterIO container.

Time getStartTime(void) const
Get the moment of the first sample processed. Throws an exception if the filter has not yet been used. Assumed to throw only exceptions derived from standard c++ exception class.

Time getCurrentTime(void) const
Get the moment of the next expected sample. Throws an exception if the filter has not yet been used. Assumed to throw only exceptions derived from standard c++ exception class.

float getPhase(void) const throw(std::range_error)
Get the current phase. Throws logic_error exception if undefined.

bool getPhase(float& phi) const throw()
Get the current phase. Returns false if undefined.
Parameters:
phi - current filter phase

float getFcHz(void) const throw(std::range_error, std::runtime_error)
Get the local oscillator frequency in units of Hz. Throws logic_error exception if undefined.

bool getFcHz(float& fc) const throw()
Get the local oscillator frequency in units of Hz. Returns false if undefined. Root-safe.

float getFcNyquist(void) const throw(std::range_error, std::runtime_error)
Get the local oscillator frequency in units of Nyquist frequency. Throws logic_error exception if undefined.

bool getFcNyquist(float& fc) const throw()
Get the local oscillator frequency in units of Nyquist frequency. Returns false if undefined. Root-safe.

void setPhase(const float& phi) throw(std::logic_error)
Set the initial phase. Throws logic_error exception if filter in use.
Parameters:
phi - initial phase of local oscillator (radians)

void setFcHz(const float& f) throw(std::logic_error)
Set the local oscillator frequency in Hz. Throws logic_error if called while filter in use.
Parameters:
f - local oscillator frequency (Hz)

void setFcNyquist(const float& f) throw(std::logic_error)
Set the local oscillator frequency in Nyquist frequency units. Throws out_of_range if oscillator frequency not in range (-1,1), logic_error if called while filter in use.
Parameters:
f - local oscillator frequency (Nyquist units)

bool inUse(void) const
Returns true if filter is in use.


This class has no child classes.
Author:
Lee Samuel Finn <LSF5@PSU.Edu>
Version:

alphabetic index hierarchy of classes


generated by doc++