SPUC::farrow< Numeric > Class Template Reference
[SPUC templatesFIR filtersInterpolation filters]

Template Class for Farrow implementation of a ploynomial interpolation using a FIR filter. More...

#include <farrow.h>

Collaboration diagram for SPUC::farrow< Numeric >:

Collaboration graph
[legend]
List of all members.

Public Member Functions

Numeric out ()
 Get current output.
Numeric check (long i)
 Clock in new sample & compute current output.
 farrow (char order)
 Need to cover different orders!
void reset (void)
 reset
 ~farrow (void)
void input (Numeric in)
 Only input new sample.
Numeric update (Numeric in, float_type offset)
Numeric fir (float_type offset)
 Calculate output for current coefficients. Offset is between 0 and 1.
Numeric rephase (float_type offset)
 Rephase => recalculate coefficients and output for new offset (for upsampling).
void calculate_coeff2 (void)
 Calculate coefficients for linear (not tested).
void calculate_coeff3 (void)
 Calculate coefficients for square.
void calculate_coeff3a (void)
 Calculate coefficients for parabolic.
void calculate_coeff4 (void)
 Calculate coefficients for 4th order.

Public Attributes

long num_taps
smart_array< Numeric > coeff

Protected Attributes

smart_array< Numeric > z
Numeric output

Detailed Description

template<class Numeric>
class SPUC::farrow< Numeric >

Template Class for Farrow implementation of a ploynomial interpolation using a FIR filter.

Farrow implementation of a polynomial interpolation This covers 3 (orders) cases of interpolation 1. Linear (not efficient using this method) 2. Piecewise-Parabolic 3. Cubic Although derived from the Lagrange coefficients the multiplication factor have been simplified to allow simple VLSI implementations. see Interpolation in Digital Modem - Part II, IEEE Trans. on Comms. June 1993.

Author:
Tony Kirke
farrow.png


Constructor & Destructor Documentation

template<class Numeric>
SPUC::farrow< Numeric >::farrow ( char  order  )  [inline]

Need to cover different orders!

template<class Numeric>
SPUC::farrow< Numeric >::~farrow ( void   )  [inline]


Member Function Documentation

template<class Numeric>
void SPUC::farrow< Numeric >::calculate_coeff2 ( void   )  [inline]

Calculate coefficients for linear (not tested).

template<class Numeric>
void SPUC::farrow< Numeric >::calculate_coeff3 ( void   )  [inline]

Calculate coefficients for square.

template<class Numeric>
void SPUC::farrow< Numeric >::calculate_coeff3a ( void   )  [inline]

Calculate coefficients for parabolic.

template<class Numeric>
void SPUC::farrow< Numeric >::calculate_coeff4 ( void   )  [inline]

Calculate coefficients for 4th order.

template<class Numeric>
Numeric SPUC::farrow< Numeric >::check ( long  i  )  [inline]

Clock in new sample & compute current output.

template<class Numeric>
Numeric SPUC::farrow< Numeric >::fir ( float_type  offset  )  [inline]

Calculate output for current coefficients. Offset is between 0 and 1.

template<class Numeric>
void SPUC::farrow< Numeric >::input ( Numeric  in  )  [inline]

Only input new sample.

template<class Numeric>
Numeric SPUC::farrow< Numeric >::out (  )  [inline]

Get current output.

template<class Numeric>
Numeric SPUC::farrow< Numeric >::rephase ( float_type  offset  )  [inline]

Rephase => recalculate coefficients and output for new offset (for upsampling).

template<class Numeric>
void SPUC::farrow< Numeric >::reset ( void   )  [inline]

reset

template<class Numeric>
Numeric SPUC::farrow< Numeric >::update ( Numeric  in,
float_type  offset 
) [inline]

: Update => Clock in new input sample, recalculate coefficients and determine output


Member Data Documentation

template<class Numeric>
smart_array<Numeric> SPUC::farrow< Numeric >::coeff

template<class Numeric>
long SPUC::farrow< Numeric >::num_taps

template<class Numeric>
Numeric SPUC::farrow< Numeric >::output [protected]

template<class Numeric>
smart_array<Numeric> SPUC::farrow< Numeric >::z [protected]


The documentation for this class was generated from the following file:
Generated on Mon Jun 9 19:40:37 2008 for DSPTemplates by  doxygen 1.4.7