SPUC  3.0
Classes | Typedefs | Functions
Miscellaneous DSP
Collaboration diagram for Miscellaneous DSP:

Classes

class  SPUC::a_d
 An A/D conversion class. More...
 
class  SPUC::circ_buffer< T >
 Circular Buffer. More...
 
class  SPUC::cordic< Numeric >
 Cordic rotator. More...
 
class  SPUC::delay< Numeric >
 Template class for Delay line. More...
 
class  SPUC::fixed_delay< Numeric, D >
 Template class for Delay line with Fixed Delay. More...
 
class  SPUC::max_pn
 Maximal Length Pseudorandom sequence generator. More...
 
class  SPUC::noise
 Gaussian noise routine. More...
 
class  SPUC::qnoise< Numeric >
 class to add quantization noise to signal More...
 
class  SPUC::quantiser< Numeric >
 ........ More...
 
class  SPUC::rv_stat
 a basic random Variable Statistics Class More...
 
class  SPUC::sigma_delta
 Simple 1st order All-digital Sigma Delta converter. More...
 

Typedefs

typedef complex< float_type > SPUC::CPLX
 General Purpose C++ complex FFT Transform. More...
 

Functions

template<class T >
std::vector< T > SPUC::auto_corr (const std::vector< T > &x)
 Compute the autocorrelation of the Vector. More...
 
template<class T >
std::vector< T > SPUC::burg (std::vector< T > x, int P)
 AR model coefficients calculation using Burg algorithm. More...
 
template<typename T >
SPUC::conj (T in)
 Templated conjugate function template function that uses a class to allow template specialization. More...
 
template<class T >
std::vector< T > SPUC::convolve (const std::vector< T > &x, const std::vector< T > &y)
 
std::vector< complex
< float_type > > 
SPUC::find_roots (const std::vector< float_type > &a, long n)
 Calculate the complex roots of a polynomial equation. More...
 
template<class T >
std::vector< T > SPUC::fliplr (const std::vector< T > &x)
 fliplr - same as matlab function More...
 
template<class T >
complex< float_type > SPUC::freqz_point (std::vector< T > b, std::vector< T > a, float_type freq, int N)
 frequency transfer function at freq with iir A and B equations More...
 
template<class T >
float_type SPUC::freqz_mag_point (std::vector< T > x, float_type freq, int N)
 frequency magnitude function at freq with fir x More...
 
template<class T >
complex< float_type > SPUC::freqz_point (T a, float_type freq)
 frequency transfer function at freq for 1st order allpass More...
 
template<class T >
std::vector< complex
< float_type > > 
SPUC::freqz (std::vector< T > b, std::vector< T > a, int pts)
 frequency transfer function over "pts" points for IIR More...
 
template<class T >
std::vector< complex
< float_type > > 
SPUC::freqz_mag (std::vector< T > b, std::vector< T > a, int pts)
 frequency magnitude function over "pts" points for IIR More...
 
template<class T >
std::vector< complex
< float_type > > 
SPUC::freqz_fir (std::vector< T > x, int pts)
 frequency magnitude function over "pts" points for FIR More...
 
template<class T >
std::vector< T > SPUC::levdur (std::vector< T > R)
 Template class for Levinson-Durbin algorithm. More...
 
template<typename T >
base_type< T >::btype SPUC::magsq (T in)
 Templated Magnitude Squared function template function that uses a class to allow template specialization. More...
 
template<class T >
std::vector< T > SPUC::partial_convolve (const std::vector< T > &x, const std::vector< T > &y, int N, int M)
 
template<class T >
complex< float_type > SPUC::ptr_freqz_point (T *b, T *a, float_type freq, int N)
 frequency transfer function at freq with iir A and B equations More...
 
template<class T >
float_type SPUC::ptr_freqz_mag_point (T *x, float_type freq, int N)
 frequency magnitude function at freq with fir x More...
 
template<class T >
complex< float_type > SPUC::ptr_freqz_point (T a, float_type freq)
 frequency transfer function at freq for 1st order allpass More...
 
template<class T >
void SPUC::freqz (complex< float_type > *f, T *b, T *a, int N, int pts)
 frequency transfer function over "pts" points for IIR More...
 
template<class T >
void SPUC::ptr_freqz_mag (float_type *f, T *b, T *a, int N, int pts)
 frequency magnitude function over "pts" points for IIR More...
 
template<class T >
void SPUC::ptr_freqz_fir (complex< float_type > *f, T *x, int N, int pts)
 frequency magnitude function over "pts" points for FIR More...
 
template<typename T >
quantized_type< T >::dtype SPUC::quantize (T in)
 Templated Quantize function template function that uses a class to allow template specialization. More...
 
template<class T >
long SPUC::real_quantize (T in)
 Templated quantize function. More...
 
template<class T >
SPUC::real_round (T in, long bits)
 Templated round function. More...
 
template<class T >
SPUC::real_saturate (T in, long bits)
 Templated saturation functions. More...
 
template<>
long SPUC::real_saturate (long in, long bits)
 Templated saturation functions. More...
 
template<class T >
SPUC::round (T in, long bits)
 Templated round function template function that uses a class to allow template specialization. More...
 
template<class T >
SPUC::saturate (T in, long bits)
 Templated saturate function template function that uses a class to allow template specialization. More...
 
template<typename T >
SPUC::signbit (T in)
 Templated signbit function template function that uses a class to allow template specialization. More...
 
template<class T >
void SPUC::toeplitz (vector< T > x, matrix< T > &A)
 Get Symmetric Toeplitz matrix from vector. More...
 
 SPUC::cfft::cfft (int size, float_type scalef1=0.5, float_type scalef2=1.0, float_type scalei1=1.0, float_type scalei2=1.0)
 General Purpose C++ complex FFT Transform. More...
 

Detailed Description

Typedef Documentation

typedef complex<float_type> SPUC::CPLX

General Purpose C++ complex FFT Transform.

This is a general-purpose C++ complex FFT transform class. it is defined as a template over a complex type. For instance, if using gnu gcc, the complex type is complex<float_type> And you declare the cfft class as cfft<complex<float_type>>

The underlying CPLX type requires: CPLX() operator = , CPLX(CPLX const&) CPLX(float_type,float_type) [used on cos/sin] CPLX operator*( CPLX , float_type ) CPLX conj(CPLX const &); [conjugate] ComPlex::operator @ (CPLX , CPLX ) [ where @ =* + - ]

Author
Tony Kirke

Function Documentation

template<class T >
std::vector<T> SPUC::auto_corr ( const std::vector< T > &  x)

Compute the autocorrelation of the Vector.

Author
Tony Kirke, Copyright(c) 2001
Tony Kirke

Referenced by main().

template<class T >
std::vector<T> SPUC::burg ( std::vector< T >  x,
int  P 
)

AR model coefficients calculation using Burg algorithm.

Author
Tony Kirke, Copyright(c) 2001
Tony Kirke

References SPUC::conj(), and SPUC::magsq().

Here is the call graph for this function:

SPUC::cfft::cfft ( int  size,
float_type  scalef1 = 0.5,
float_type  scalef2 = 1.0,
float_type  scalei1 = 1.0,
float_type  scalei2 = 1.0 
)

General Purpose C++ complex FFT Transform.

References SPUC::conj(), SPUC::cos(), and PI.

Here is the call graph for this function:

template<typename T >
T SPUC::conj ( in)
template<class T >
std::vector<T> SPUC::convolve ( const std::vector< T > &  x,
const std::vector< T > &  y 
)
Author
Tony Kirke, Copyright(c) 2001
Tony Kirke

References M.

Referenced by SPUC::iir_coeff::pz_to_ap().

std::vector< complex< float_type > > SPUC::find_roots ( const std::vector< float_type > &  a,
long  n 
)

Calculate the complex roots of a polynomial equation.

Author
Tony Kirke

References SPUC::exp(), and SPUC::sqrt().

Referenced by main(), and SPUC::iir_coeff::pz_to_ap().

Here is the call graph for this function:

template<class T >
std::vector<T> SPUC::fliplr ( const std::vector< T > &  x)

fliplr - same as matlab function

Author
Tony Kirke

Referenced by SPUC::iir_coeff::pz_to_ap().

template<class T >
void SPUC::freqz ( complex< float_type > *  f,
T *  b,
T *  a,
int  N,
int  pts 
)

frequency transfer function over "pts" points for IIR

Author
Tony Kirke

References SPUC::cos(), and PI.

Here is the call graph for this function:

template<class T >
std::vector<complex<float_type> > SPUC::freqz ( std::vector< T >  b,
std::vector< T >  a,
int  pts 
)

frequency transfer function over "pts" points for IIR

Author
Tony Kirke

References SPUC::cos(), and PI.

Here is the call graph for this function:

template<class T >
std::vector<complex<float_type> > SPUC::freqz_fir ( std::vector< T >  x,
int  pts 
)

frequency magnitude function over "pts" points for FIR

Author
Tony Kirke

References SPUC::cos(), and PI.

Here is the call graph for this function:

template<class T >
std::vector<complex<float_type> > SPUC::freqz_mag ( std::vector< T >  b,
std::vector< T >  a,
int  pts 
)

frequency magnitude function over "pts" points for IIR

Author
Tony Kirke

References SPUC::cos(), SPUC::magsq(), and PI.

Here is the call graph for this function:

template<class T >
float_type SPUC::freqz_mag_point ( std::vector< T >  x,
float_type  freq,
int  N 
)

frequency magnitude function at freq with fir x

Author
Tony Kirke

References SPUC::expj(), and SPUC::hypot().

Here is the call graph for this function:

template<class T >
complex<float_type> SPUC::freqz_point ( std::vector< T >  b,
std::vector< T >  a,
float_type  freq,
int  N 
)

frequency transfer function at freq with iir A and B equations

Author
Tony Kirke

References SPUC::cos().

Here is the call graph for this function:

template<class T >
complex<float_type> SPUC::freqz_point ( a,
float_type  freq 
)

frequency transfer function at freq for 1st order allpass

Author
Tony Kirke

References SPUC::cos(), and SPUC::normalized().

Here is the call graph for this function:

template<class T >
std::vector<T> SPUC::levdur ( std::vector< T >  R)

Template class for Levinson-Durbin algorithm.

<font color="red">Under construction!</font>

Author
Tony Kirke
template<typename T >
base_type< T >::btype SPUC::magsq ( in)
template<class T >
std::vector<T> SPUC::partial_convolve ( const std::vector< T > &  x,
const std::vector< T > &  y,
int  N,
int  M 
)
Author
Tony Kirke, Copyright(c) 2001
Tony Kirke

References M.

Referenced by SPUC::iir_coeff::p2_to_poly(), and SPUC::iir_coeff::pz_to_poly().

template<class T >
void SPUC::ptr_freqz_fir ( complex< float_type > *  f,
T *  x,
int  N,
int  pts 
)

frequency magnitude function over "pts" points for FIR

Author
Tony Kirke

References SPUC::cos(), and PI.

Here is the call graph for this function:

template<class T >
void SPUC::ptr_freqz_mag ( float_type *  f,
T *  b,
T *  a,
int  N,
int  pts 
)

frequency magnitude function over "pts" points for IIR

Author
Tony Kirke

References SPUC::cos(), SPUC::magsq(), and PI.

Here is the call graph for this function:

template<class T >
float_type SPUC::ptr_freqz_mag_point ( T *  x,
float_type  freq,
int  N 
)

frequency magnitude function at freq with fir x

Author
Tony Kirke

References SPUC::expj(), and SPUC::hypot().

Here is the call graph for this function:

template<class T >
complex<float_type> SPUC::ptr_freqz_point ( T *  b,
T *  a,
float_type  freq,
int  N 
)

frequency transfer function at freq with iir A and B equations

Author
Tony Kirke

References SPUC::cos().

Here is the call graph for this function:

template<class T >
complex<float_type> SPUC::ptr_freqz_point ( a,
float_type  freq 
)

frequency transfer function at freq for 1st order allpass

Author
Tony Kirke

References SPUC::cos(), and SPUC::normalized().

Here is the call graph for this function:

template<typename T >
quantized_type<T>::dtype SPUC::quantize ( in)

Templated Quantize function template function that uses a class to allow template specialization.

Author
Tony Kirke

References SPUC::quantizer< Numeric >::quantized().

Here is the call graph for this function:

template<class T >
long SPUC::real_quantize ( in)
template<class T >
T SPUC::real_round ( in,
long  bits 
)

Templated round function.

Author
Tony Kirke

Referenced by SPUC::rounder< Numeric >::rounded(), and SPUC::rounder< complex< T > >::rounded().

template<class T >
T SPUC::real_saturate ( in,
long  bits 
)

Templated saturation functions.

Author
Tony Kirke

Referenced by SPUC::saturater< Numeric >::saturated(), and SPUC::saturater< complex< T > >::saturated().

template<>
long SPUC::real_saturate ( long  in,
long  bits 
)
inline

Templated saturation functions.

Author
Tony Kirke

References SPUC::ABS().

Here is the call graph for this function:

template<class T >
T SPUC::round ( in,
long  bits 
)
template<class T >
T SPUC::saturate ( in,
long  bits 
)

Templated saturate function template function that uses a class to allow template specialization.

Author
Tony Kirke

Referenced by SPUC::qpsk_variable< Numeric >::clock(), and SPUC::qpsk_discriminators::pll_disc().

template<typename T >
T SPUC::signbit ( in)

Templated signbit function template function that uses a class to allow template specialization.

Author
Tony Kirke

Referenced by SPUC::qpsk< Numeric >::clock(), SPUC::qpsk_variable< Numeric >::clock(), SPUC::fir_adapt< Numeric, Numeric >::update_lms(), and SPUC::fir_adapt< Numeric, Numeric >::update_lms_sign_coeff().

template<class T >
void SPUC::toeplitz ( vector< T >  x,
matrix< T > &  A 
)

Get Symmetric Toeplitz matrix from vector.

Author
Tony Kirke, Copyright(c) 2001
Tony Kirke

References SPUC::vector< T >::size().

Here is the call graph for this function: