Fixed-point Module

Fixed-Point Data Types. More...

## Classes

class | itpp::CFix
| Complex fixed-point data type. More...
class | itpp::CFixed< w, e, o, q >
| Templated complex fixed-point data type. More...
class | itpp::Fix
| Fixed-point data type. More...
class | itpp::Fix_Base
| Base class for fixed-point data types. More...
class | itpp::Fix_Factory
| Class factory for fixed-point data types Fix and CFix. More...
class | itpp::Fixed< w, e, o, q >
| Templated fixed-point data type. More...

## Typedefs

typedef Vec< CFix > | itpp::cfixvec
| Typedef for complex fixed-point vector type.
typedef Mat< CFix > | itpp::cfixmat
| Typedef for complex fixed-point matrix type.
typedef Vec< Fix > | itpp::fixvec
| Typedef for fixed-point vector type.
typedef Mat< Fix > | itpp::fixmat
| Typedef for fixed-point matrix type.
typedef int64_t | itpp::fixrep
| Representation for fixed-point data types.

## Enumerations

enum | itpp::e_mode { itpp::TC , itpp::US }
| Sign encoding modes (aligned with SystemC) More...
enum | itpp::o_mode { itpp::SAT , itpp::SAT_ZERO , itpp::SAT_SYM , itpp::WRAP , itpp::WRAP_SM }
| Overflow modes (aligned with SystemC) More...
enum | itpp::q_mode { itpp::RND , itpp::RND_ZERO , itpp::RND_MIN_INF , itpp::RND_INF , itpp::RND_CONV , itpp::RND_CONV_ODD , itpp::TRN , itpp::TRN_ZERO }
| Quantization modes (aligned with SystemC) More...
enum | itpp::output_mode { itpp::OUTPUT_FIX , itpp::OUTPUT_FIX_SHIFT , itpp::OUTPUT_FLOAT , itpp::OUTPUT_FLOAT_SHIFT }
| Output modes. More...

## Functions

int | itpp::assert_shifts (const CFix &x, const CFix &y)
| Check that x.shift==y.shift OR x==0 OR y==0 and return the shift (for the non-zero argument)
int | itpp::assert_shifts (const CFix &x, const Fix &y)
| Check that x.shift==y.shift OR x==0 OR y==0 and return the shift (for the non-zero argument)
int | itpp::assert_shifts (const CFix &x, int y)
| Check that x.shift==0 OR x==0 OR y==0 and return x.shift.
std::istream & | itpp::operator>> (std::istream &is, CFix &x)
| Input bit representation and, optionally, the shift.
std::ostream & | itpp::operator<< (std::ostream &os, const CFix &x)
| Output bit representation and, optionally, the shift.
int | itpp::assert_shifts (const Fix &x, const Fix &y)
| Check that x.shift==y.shift OR x==0 OR y==0 and return the shift (for the non-zero argument)
int | itpp::assert_shifts (const Fix &x, int y)
| Check that x.shift==0 OR x==0 OR y==0 and return x.shift.
std::istream & | itpp::operator>> (std::istream &is, Fix &x)
| Input bit representation and, optionally, the shift.
std::ostream & | itpp::operator<< (std::ostream &os, const Fix &x)
| Output bit representation and, optionally, the shift.
std::ostream & | itpp::operator<< (std::ostream &os, const output_mode &o)
| Set output mode.
template<>
ITPP_EXPORT void | itpp::create_elements< Fix > (Fix *&ptr, const int n, const Factory &f)
| Create an n-length array of Fix using Fix_Factory `f`.
template<>
ITPP_EXPORT void | itpp::create_elements< CFix > (CFix *&ptr, const int n, const Factory &f)
| Create an n-length array of CFix using Fix_Factory `f`.
template<class T >
bool | itpp::is_fix (const T &)
| Return true only if argument is of type Fix or CFix (or an Array/Vec/Mat of Fix or CFix)
template<>
bool | itpp::is_fix (const Fix &)
| Return true only if argument is of type Fix or CFix (or an Array/Vec/Mat of Fix or CFix)
template<>
bool | itpp::is_fix (const fixvec &)
| Return true only if argument is of type Fix or CFix (or an Array/Vec/Mat of Fix or CFix)
template<>
bool | itpp::is_fix (const fixmat &)
| Return true only if argument is of type Fix or CFix (or an Array/Vec/Mat of Fix or CFix)
template<>
bool | itpp::is_fix (const CFix &)
| Return true only if argument is of type Fix or CFix (or an Array/Vec/Mat of Fix or CFix)
template<>
bool | itpp::is_fix (const cfixvec &)
| Return true only if argument is of type Fix or CFix (or an Array/Vec/Mat of Fix or CFix)
template<>
bool | itpp::is_fix (const cfixmat &)
| Return true only if argument is of type Fix or CFix (or an Array/Vec/Mat of Fix or CFix)
template<class T >
bool | itpp::is_fix (const Array< T > &)
| Return true only if argument is of type Fix or CFix (or an Array/Vec/Mat of Fix or CFix)
void | itpp::set_fix (Fix &y, double x, int n)
| Set `y = x * pow2(n)` using the quantization mode of `y`.
void | itpp::set_fix (Fix &y, double x, int n, q_mode q)
| Set `y = x * pow2(n)` using the specified quantization mode `q`.
void | itpp::set_fix (fixvec &y, const vec &x, int n)
| Set `y = x * pow2(n)` using the quantization mode of `y`.
void | itpp::set_fix (fixvec &y, const vec &x, int n, q_mode q)
| Set `y = x * pow2(n)` using the specified quantization mode `q`.
void | itpp::set_fix (fixmat &y, const mat &x, int n)
| Set `y = x * pow2(n)` using the quantization mode of `y`.
void | itpp::set_fix (fixmat &y, const mat &x, int n, q_mode q)
| Set `y = x * pow2(n)` using the specified quantization mode `q`.
void | itpp::set_fix (double &y, double x, int)
| Set `y = x`. Useful in templated code.
void | itpp::set_fix (double &y, double x, int, q_mode)
| Set `y = x`. Useful in templated code.
void | itpp::set_fix (vec &y, const vec &x, int)
| Set `y = x`. Useful in templated code.
void | itpp::set_fix (vec &y, const vec &x, int, q_mode)
| Set `y = x`. Useful in templated code.
void | itpp::set_fix (mat &y, const mat &x, int)
| Set `y = x`. Useful in templated code.
void | itpp::set_fix (mat &y, const mat &x, int, q_mode)
| Set `y = x`. Useful in templated code.
void | itpp::set_fix (CFix &y, std::complex< double > x, int n)
| Set `y = x * pow2(n)` using the quantization mode of `y`.
void | itpp::set_fix (CFix &y, double real, double imag, int n)
| Set `y = (real + i*imag) * pow2(n)` using the quantization mode of `y`.
void | itpp::set_fix (CFix &y, std::complex< double > x, int n, q_mode q)
| Set `y = x * pow2(n)` using the specified quantization mode `q`.
void | itpp::set_fix (CFix &y, double real, double imag, int n, q_mode q)
| Set `y = (real + i*imag) * pow2(n)` using the specified quantization mode `q`.
void | itpp::set_fix (cfixvec &y, const cvec &x, int n)
| Set `y = x * pow2(n)` using the quantization mode of `y`.
void | itpp::set_fix (cfixvec &y, const vec &real, const vec &imag, int n)
| Set `y = (real + i*imag) * pow2(n)` using the quantization mode of `y`.
void | itpp::set_fix (cfixvec &y, const cvec &x, int n, q_mode q)
| Set `y = x * pow2(n)` using the specified quantization mode `q`.
void | itpp::set_fix (cfixvec &y, const vec &real, const vec &imag, int n, q_mode q)
| Set `y = (real + i*imag) * pow2(n)` using the specified quantization mode `q`.
void | itpp::set_fix (cfixmat &y, const cmat &x, int n)
| Set `y = x * pow2(n)` using the quantization mode of `y`.
void | itpp::set_fix (cfixmat &y, const mat &real, const mat &imag, int n)
| Set `y = (real + i*imag) * pow2(n)` using the quantization mode of `y`.
void | itpp::set_fix (cfixmat &y, const cmat &x, int n, q_mode q)
| Set `y = x * pow2(n)` using the specified quantization mode `q`.
void | itpp::set_fix (cfixmat &y, const mat &real, const mat &imag, int n, q_mode q)
| Set `y = (real + i*imag) * pow2(n)` using the specified quantization mode `q`.
void | itpp::set_fix (std::complex< double > &y, const std::complex< double > &x, int)
| Set `y = x`. Useful in templated code.
void | itpp::set_fix (std::complex< double > &y, double real, double imag, int)
| Set `y = real + i*imag`. Useful in templated code.
void | itpp::set_fix (std::complex< double > &y, const std::complex< double > &x, int, q_mode)
| Set `y = x`. Useful in templated code.
void | itpp::set_fix (std::complex< double > &y, double real, double imag, int, q_mode)
| Set `y = real + i*imag`. Useful in templated code.
void | itpp::set_fix (cvec &y, const cvec &x, int)
| Set `y = x`. Useful in templated code.
void | itpp::set_fix (cvec &y, const vec &real, const vec &imag, int)
| Set `y = real + i*imag`. Useful in templated code.
void | itpp::set_fix (cvec &y, const cvec &x, int, q_mode)
| Set `y = x`. Useful in templated code.
void | itpp::set_fix (cvec &y, const vec &real, const vec &imag, int, q_mode)
| Set `y = real + i*imag`. Useful in templated code.
void | itpp::set_fix (cmat &y, const cmat &x, int)
| Set `y = x`. Useful in templated code.
void | itpp::set_fix (cmat &y, const mat &real, const mat &imag, int)
| Set `y = real + i*imag`. Useful in templated code.
void | itpp::set_fix (cmat &y, const cmat &x, int, q_mode)
| Set `y = x`. Useful in templated code.
void | itpp::set_fix (cmat &y, const mat &real, const mat &imag, int, q_mode)
| Set `y = real + i*imag`. Useful in templated code.
template<class T1 , class T2 >
void | itpp::set_fix (Array< T1 > &y, const Array< T2 > &x, int n)
| Call set_fix for each Array element.
template<class T1 , class T2 >
void | itpp::set_fix (Array< T1 > &y, const Array< T2 > &real, const Array< T2 > &imag, int n)
| Call set_fix for each Array element.
template<class T1 , class T2 >
void | itpp::set_fix (Array< T1 > &y, const Array< T2 > &x, int n, q_mode q)
| Call set_fix for each Array element.
template<class T1 , class T2 >
void | itpp::set_fix (Array< T1 > &y, const Array< T2 > &real, const Array< T2 > &imag, int n, q_mode q)
| Call set_fix for each Array element.
void | itpp::lshift_fix (Fix &y, int n)
| Left shift `n` bits.
void | itpp::rshift_fix (Fix &y, int n)
| Right shift `n` bits using the quantization mode of `y`.
void | itpp::rshift_fix (Fix &y, int n, q_mode q)
| Right shift `n` bits using the specified quantization mode `q`.
void | itpp::lshift_fix (fixvec &y, int n)
| Left shift `n` bits.
void | itpp::rshift_fix (fixvec &y, int n)
| Right shift `n` bits using the quantization mode of `y`.
void | itpp::rshift_fix (fixvec &y, int n, q_mode q)
| Right shift `n` bits using the specified quantization mode `q`.
void | itpp::lshift_fix (fixmat &y, int n)
| Left shift `n` bits.
void | itpp::rshift_fix (fixmat &y, int n)
| Right shift `n` bits using the quantization mode of `y`.
void | itpp::rshift_fix (fixmat &y, int n, q_mode q)
| Right shift `n` bits using the specified quantization mode `q`.
void | itpp::lshift_fix (double &, int)
| Dummy function useful in templated code.
void | itpp::rshift_fix (double &, int)
| Dummy function useful in templated code.
void | itpp::rshift_fix (double &, int, q_mode)
| Dummy function useful in templated code.
void | itpp::lshift_fix (vec &, int)
| Dummy function useful in templated code.
void | itpp::rshift_fix (vec &, int)
| Dummy function useful in templated code.
void | itpp::rshift_fix (vec &, int, q_mode)
| Dummy function useful in templated code.
void | itpp::lshift_fix (mat &, int)
| Dummy function useful in templated code.
void | itpp::rshift_fix (mat &, int)
| Dummy function useful in templated code.
void | itpp::rshift_fix (mat &, int, q_mode)
| Dummy function useful in templated code.
void | itpp::lshift_fix (CFix &y, int n)
| Left shift `n` bits.
void | itpp::rshift_fix (CFix &y, int n)
| Right shift `n` bits using the quantization mode of `y`.
void | itpp::rshift_fix (CFix &y, int n, q_mode q)
| Right shift `n` bits using the specified quantization mode `q`.
void | itpp::lshift_fix (cfixvec &y, int n)
| Left shift `n` bits.
void | itpp::rshift_fix (cfixvec &y, int n)
| Right shift `n` bits using the quantization mode of `y`.
void | itpp::rshift_fix (cfixvec &y, int n, q_mode q)
| Right shift `n` bits using the specified quantization mode `q`.
void | itpp::lshift_fix (cfixmat &y, int n)
| Left shift `n` bits.
void | itpp::rshift_fix (cfixmat &y, int n)
| Right shift `n` bits using the quantization mode of `y`.
void | itpp::rshift_fix (cfixmat &y, int n, q_mode q)
| Right shift `n` bits using the specified quantization mode `q`.
void | itpp::lshift_fix (std::complex< double > &, int)
| Dummy function useful in templated code.
void | itpp::rshift_fix (std::complex< double > &, int)
| Dummy function useful in templated code.
void | itpp::rshift_fix (std::complex< double > &, int, q_mode)
| Dummy function useful in templated code.
void | itpp::lshift_fix (cvec &, int)
| Dummy function useful in templated code.
void | itpp::rshift_fix (cvec &, int)
| Dummy function useful in templated code.
void | itpp::rshift_fix (cvec &, int, q_mode)
| Dummy function useful in templated code.
void | itpp::lshift_fix (cmat &, int)
| Dummy function useful in templated code.
void | itpp::rshift_fix (cmat &, int)
| Dummy function useful in templated code.
void | itpp::rshift_fix (cmat &, int, q_mode)
| Dummy function useful in templated code.
template<class T >
void | itpp::lshift_fix (Array< T > &y, int n)
| Call lshift_fix for each Array element.
template<class T >
void | itpp::rshift_fix (Array< T > &y, int n)
| Call rshift_fix for each Array element.
template<class T >
void | itpp::rshift_fix (Array< T > &y, int n, q_mode q)
| Call rshift_fix for each Array element.
void | itpp::assert_fixshift (double, int)
| If x is a fixed-point variable, assert that x has the specified shift value, otherwise do nothing.
void | itpp::assert_fixshift (const std::complex< double > &, int)
| If x is a fixed-point variable, assert that x has the specified shift value, otherwise do nothing.
void | itpp::assert_fixshift (const Fix &x, int shift)
| If x is a fixed-point variable, assert that x has the specified shift value, otherwise do nothing.
void | itpp::assert_fixshift (const CFix &x, int shift)
| If x is a fixed-point variable, assert that x has the specified shift value, otherwise do nothing.
vec | itpp::to_vec (const fixvec &v)
| Converts a fixvec to vec.
cvec | itpp::to_cvec (const cfixvec &v)
| Converts a cfixvec to cvec.
mat | itpp::to_mat (const fixmat &m)
| Converts a fixmat to mat.
cmat | itpp::to_cmat (const cfixmat &m)
| Converts a cfixmat to cmat.
template<class T >
T | itpp::to (double x)
| Convert double to T.
template<class T >
T | itpp::to (const Fix &x)
| Convert Fix to T.
template<class T >
T | itpp::to (const std::complex< double > &x)
| Convert std::complex<double> to T.
template<class T >
T | itpp::to (const CFix &x)
| Convert CFix to T.
template<class T >
T | itpp::to (double real, double imag)
| Convert double (real and imaginary parts) to T.
template<class T >
T | itpp::to (const Fix &real, const Fix &imag)
| Convert Fix (real and imaginary parts) to T.
template<class T , class U >
Vec< T > | itpp::to (const Vec< U > &x)
| Convert Vec to Vec<T>
template<>
vec | itpp::to< double > (const vec &x)
| Convert vec to vec.
template<>
cvec | itpp::to< std::complex< double > > (const cvec &x)
| Convert cvec to cvec.
template<>
fixvec | itpp::to< Fix > (const fixvec &x)
| Convert fixvec to fixvec.
template<>
cfixvec | itpp::to< CFix > (const cfixvec &x)
| Convert cfixvec to cfixvec.
template<class T , class U >
Vec< T > | itpp::to (const Vec< U > &real, const Vec< U > &imag)
| Convert Vec (real and imaginary parts) to Vec<T>
template<class T , class U >
Mat< T > | itpp::to (const Mat< U > &x)
| Convert Mat to Mat<T>
template<>
mat | itpp::to< double > (const mat &x)
| Convert mat to mat.
template<>
cmat | itpp::to< std::complex< double > > (const cmat &x)
| Convert cmat to cmat.
template<>
fixmat | itpp::to< Fix > (const fixmat &x)
| Convert fixmat to fixmat.
template<>
cfixmat | itpp::to< CFix > (const cfixmat &x)
| Convert cfixmat to cfixmat.
template<class T , class U >
Mat< T > | itpp::to (const Mat< U > &real, const Mat< U > &imag)
| Convert Mat (real and imaginary parts) to Mat<T>
template<class T , class U >
Array< typename ConvertU2T< T, U >::result > | itpp::to (const Array< U > &x)
| Convert Array, where U can be an Array/Vec/Mat, to a corresponding Array with T elements.
template<class T , class U >
Array< typename ConvertU2T< T, U >::result > | itpp::to (const Array< U > &real, const Array< U > &imag)
| Convert Array (real and imaginary parts), where U can be an Array/Vec/Mat, to a corresponding Array with T elements.
double | itpp::unfix (const Fix &x)
| Convert Fix to double by multiplying the bit representation with pow2(-shift)
std::complex< double > | itpp::unfix (const CFix &x)
| Convert CFix to std::complex<double> by multiplying the bit representation with pow2(-shift)
vec | itpp::unfix (const fixvec &x)
| Convert fixvec to vec by multiplying the bit representations with pow2(-shift)
cvec | itpp::unfix (const cfixvec &x)
| Convert cfixvec to cvec by multiplying the bit representations with pow2(-shift)
mat | itpp::unfix (const fixmat &x)
| Convert fixmat to mat by multiplying the bit representations with pow2(-shift)
cmat | itpp::unfix (const cfixmat &x)
| Convert cfixmat to cmat by multiplying the bit representations with pow2(-shift)
double | itpp::unfix (double x)
| Convert double to double i.e. do nothing.
std::complex< double > | itpp::unfix (const std::complex< double > &x)
| Convert std::complex<double> to std::complex<double> i.e. do nothing.
vec | itpp::unfix (const vec &x)
| Convert vec to vec i.e. do nothing.
cvec | itpp::unfix (const cvec &x)
| Convert cvec to cvec i.e. do nothing.
mat | itpp::unfix (const mat &x)
| Convert mat to mat i.e. do nothing.
cmat | itpp::unfix (const cmat &x)
| Convert cmat to cmat i.e. do nothing.
template<class T >
Array< typename Convert< T >::to_double > | itpp::unfix (const Array< T > &x)
| Convert floating- or fixed-point Array to floating-point Array.
Fix | itpp::abs (const Fix &x)
| Absolute value.
Fix | itpp::real (const CFix &x)
| Real part of complex value.
Fix | itpp::imag (const CFix &x)
| Imaginary part of complex value.
CFix | itpp::conj (const CFix &x)
| Conjugate of complex value.
Fix | itpp::operator+ (const Fix &x, const Fix &y)
| Fix + Fix.
Fix | itpp::operator- (const Fix &x, const Fix &y)
| Fix - Fix.
Fix | itpp::operator* (const Fix &x, const Fix &y)
| Fix * Fix.
Fix | itpp::operator/ (const Fix &x, const Fix &y)
| Fix / Fix using quantization mode `TRN`.
Fix | itpp::operator+ (const Fix &x, const int y)
| Fix + int.
Fix | itpp::operator- (const Fix &x, const int y)
| Fix - int.
Fix | itpp::operator* (const Fix &x, const int y)
| Fix * int.
Fix | itpp::operator/ (const Fix &x, const int y)
| Fix / int using quantization mode `TRN`.
Fix | itpp::operator+ (const int x, const Fix &y)
| int + Fix
Fix | itpp::operator- (const int x, const Fix &y)
| int - Fix
Fix | itpp::operator* (const int x, const Fix &y)
| int * Fix
Fix | itpp::operator/ (const int x, const Fix &y)
| int / Fix using quantization mode `TRN`
fixvec | itpp::operator+ (const fixvec &v, const int s)
| fixvec + int
fixvec | itpp::operator+ (const int s, const fixvec &v)
| int + fixvec
fixvec | itpp::operator- (const fixvec &v, const int s)
| fixvec - int
fixvec | itpp::operator- (const int s, const fixvec &v)
| int - fixvec
fixvec | itpp::operator* (const fixvec &v, const int s)
| fixvec * int
fixvec | itpp::operator* (const int s, const fixvec &v)
| int * fixvec
fixvec | itpp::operator/ (const fixvec &v, const int s)
| fixvec / int using quantization mode `TRN`
fixmat | itpp::operator+ (const fixmat &v, const int s)
| fixmat + int
fixmat | itpp::operator+ (const int s, const fixmat &v)
| int + fixmat
fixmat | itpp::operator- (const fixmat &v, const int s)
| fixmat - int
fixmat | itpp::operator- (const int s, const fixmat &v)
| int - fixmat
fixmat | itpp::operator* (const fixmat &v, const int s)
| fixmat * int
fixmat | itpp::operator* (const int s, const fixmat &v)
| int * fixmat
fixmat | itpp::operator/ (const fixmat &v, const int s)
| fixmat / int using quantization mode `TRN`
fixvec | itpp::operator+ (const fixvec &a, const ivec &b)
| fixvec + ivec
fixvec | itpp::operator+ (const ivec &a, const fixvec &b)
| ivec + fixvec
fixvec | itpp::operator- (const fixvec &a, const ivec &b)
| fixvec - ivec
fixvec | itpp::operator- (const ivec &a, const fixvec &b)
| ivec - fixvec
Fix | itpp::operator* (const fixvec &a, const ivec &b)
| fixvec * ivec
Fix | itpp::operator* (const ivec &a, const fixvec &b)
| ivec * fixvec
fixmat | itpp::operator+ (const fixmat &a, const imat &b)
| fixmat + imat
fixmat | itpp::operator+ (const imat &a, const fixmat &b)
| imat + fixmat
fixmat | itpp::operator- (const fixmat &a, const imat &b)
| fixmat - imat
fixmat | itpp::operator- (const imat &a, const fixmat &b)
| imat - fixmat
fixmat | itpp::operator* (const fixmat &a, const imat &b)
| fixmat * imat
fixmat | itpp::operator* (const imat &a, const fixmat &b)
| imat * fixmat
CFix | itpp::operator+ (const CFix &x, const CFix &y)
| CFix + CFix.
CFix | itpp::operator- (const CFix &x, const CFix &y)
| CFix - CFix.
CFix | itpp::operator* (const CFix &x, const CFix &y)
| CFix * CFix.
CFix | itpp::operator/ (const CFix &x, const CFix &y)
| CFix / CFix using quantization mode `TRN`.
CFix | itpp::operator+ (const CFix &x, const Fix &y)
| CFix + Fix.
CFix | itpp::operator- (const CFix &x, const Fix &y)
| CFix - Fix.
CFix | itpp::operator* (const CFix &x, const Fix &y)
| CFix * Fix.
CFix | itpp::operator/ (const CFix &x, const Fix &y)
| CFix / Fix using quantization mode `TRN`.
CFix | itpp::operator+ (const Fix &x, const CFix &y)
| Fix + CFix.
CFix | itpp::operator- (const Fix &x, const CFix &y)
| Fix - CFix.
CFix | itpp::operator* (const Fix &x, const CFix &y)
| Fix * CFix.
CFix | itpp::operator/ (const Fix &x, const CFix &y)
| Fix / CFix using quantization mode `TRN`.
CFix | itpp::operator+ (const CFix &x, const int y)
| CFix + int.
CFix | itpp::operator- (const CFix &x, const int y)
| CFix - int.
CFix | itpp::operator* (const CFix &x, const int y)
| CFix * int.
CFix | itpp::operator/ (const CFix &x, const int y)
| CFix / int using quantization mode `TRN`.
CFix | itpp::operator+ (const int x, const CFix &y)
| int + CFix
CFix | itpp::operator- (const int x, const CFix &y)
| int - CFix
CFix | itpp::operator* (const int x, const CFix &y)
| int * CFix
CFix | itpp::operator/ (const int x, const CFix &y)
| int / CFix using quantization mode `TRN`
cfixvec | itpp::operator+ (const fixvec &v, const CFix &s)
| fixvec + CFix
cfixvec | itpp::operator+ (const CFix &s, const fixvec &v)
| CFix + fixvec.
cfixvec | itpp::operator- (const fixvec &v, const CFix &s)
| fixvec - CFix
cfixvec | itpp::operator- (const CFix &s, const fixvec &v)
| CFix - fixvec.
cfixvec | itpp::operator* (const fixvec &v, const CFix &s)
| fixvec * CFix
cfixvec | itpp::operator* (const CFix &s, const fixvec &v)
| CFix * fixvec.
cfixvec | itpp::operator/ (const fixvec &v, const CFix &s)
| fixvec / CFix using quantization mode `TRN`
cfixmat | itpp::operator+ (const fixmat &m, const CFix &s)
| fixmat + CFix
cfixmat | itpp::operator+ (const CFix &s, const fixmat &m)
| CFix + fixmat.
cfixmat | itpp::operator- (const fixmat &m, const CFix &s)
| fixmat - CFix
cfixmat | itpp::operator- (const CFix &s, const fixmat &m)
| CFix - fixmat.
cfixmat | itpp::operator* (const fixmat &m, const CFix &s)
| fixmat * CFix
cfixmat | itpp::operator* (const CFix &s, const fixmat &m)
| CFix * fixmat.
cfixmat | itpp::operator/ (const fixmat &m, const CFix &s)
| fixmat / CFix using quantization mode `TRN`
cfixvec | itpp::operator+ (const ivec &v, const CFix &s)
| ivec + CFix
cfixvec | itpp::operator+ (const CFix &s, const ivec &v)
| CFix + ivec.
cfixvec | itpp::operator- (const ivec &v, const CFix &s)
| ivec - CFix
cfixvec | itpp::operator- (const CFix &s, const ivec &v)
| CFix - ivec.
cfixvec | itpp::operator* (const ivec &v, const CFix &s)
| ivec * CFix
cfixvec | itpp::operator* (const CFix &s, const ivec &v)
| CFix * ivec.
cfixvec | itpp::operator/ (const ivec &v, const CFix &s)
| ivec / CFix using quantization mode `TRN`
cfixmat | itpp::operator+ (const imat &m, const CFix &s)
| imat + CFix
cfixmat | itpp::operator+ (const CFix &s, const imat &m)
| CFix + imat.
cfixmat | itpp::operator- (const imat &m, const CFix &s)
| imat - CFix
cfixmat | itpp::operator- (const CFix &s, const imat &m)
| CFix - imat.
cfixmat | itpp::operator* (const imat &m, const CFix &s)
| imat * CFix
cfixmat | itpp::operator* (const CFix &s, const imat &m)
| CFix * imat.
cfixmat | itpp::operator/ (const imat &m, const CFix &s)
| imat / CFix using quantization mode `TRN`
cfixvec | itpp::operator+ (const cfixvec &v, const Fix &s)
| cfixvec + Fix
cfixvec | itpp::operator+ (const Fix &s, const cfixvec &v)
| Fix + cfixvec.
cfixvec | itpp::operator- (const cfixvec &v, const Fix &s)
| cfixvec - Fix
cfixvec | itpp::operator- (const Fix &s, const cfixvec &v)
| Fix - cfixvec.
cfixvec | itpp::operator* (const cfixvec &v, const Fix &s)
| cfixvec * Fix
cfixvec | itpp::operator* (const Fix &s, const cfixvec &v)
| Fix * cfixvec.
cfixvec | itpp::operator/ (const cfixvec &v, const Fix &s)
| cfixvec / Fix using quantization mode `TRN`
cfixmat | itpp::operator+ (const cfixmat &m, const Fix &s)
| cfixmat + Fix
cfixmat | itpp::operator+ (const Fix &s, const cfixmat &m)
| Fix + cfixmat.
cfixmat | itpp::operator- (const cfixmat &m, const Fix &s)
| cfixmat - Fix
cfixmat | itpp::operator- (const Fix &s, const cfixmat &m)
| Fix - cfixmat.
cfixmat | itpp::operator* (const cfixmat &m, const Fix &s)
| cfixmat * Fix
cfixmat | itpp::operator* (const Fix &s, const cfixmat &m)
| Fix * cfixmat.
cfixmat | itpp::operator/ (const cfixmat &m, const Fix &s)
| cfixmat / Fix using quantization mode `TRN`
cfixvec | itpp::operator+ (const cfixvec &v, const int s)
| cfixvec + int
cfixvec | itpp::operator+ (const int s, const cfixvec &v)
| int + cfixvec
cfixvec | itpp::operator- (const cfixvec &v, const int s)
| cfixvec - int
cfixvec | itpp::operator- (const int s, const cfixvec &v)
| int - cfixvec
cfixvec | itpp::operator* (const cfixvec &v, const int s)
| cfixvec * int
cfixvec | itpp::operator* (const int s, const cfixvec &v)
| int * cfixvec
cfixvec | itpp::operator/ (const cfixvec &v, const int s)
| cfixvec / int using quantization mode `TRN`
cfixmat | itpp::operator+ (const cfixmat &m, const int s)
| cfixmat + int
cfixmat | itpp::operator+ (const int s, const cfixmat &m)
| int + cfixmat
cfixmat | itpp::operator- (const cfixmat &m, const int s)
| cfixmat - int
cfixmat | itpp::operator- (const int s, const cfixmat &m)
| int - cfixmat
cfixmat | itpp::operator* (const cfixmat &m, const int s)
| cfixmat * int
cfixmat | itpp::operator* (const int s, const cfixmat &m)
| int * cfixmat
cfixmat | itpp::operator/ (const cfixmat &m, const int s)
| cfixmat / int using quantization mode `TRN`
cfixvec | itpp::operator+ (const cfixvec &a, const fixvec &b)
| cfixvec + fixvec
cfixvec | itpp::operator+ (const fixvec &a, const cfixvec &b)
| fixvec + cfixvec
cfixvec | itpp::operator- (const cfixvec &a, const fixvec &b)
| cfixvec - fixvec
cfixvec | itpp::operator- (const fixvec &a, const cfixvec &b)
| fixvec - cfixvec
CFix | itpp::operator* (const cfixvec &a, const fixvec &b)
| cfixvec * fixvec
CFix | itpp::operator* (const fixvec &a, const cfixvec &b)
| fixvec * cfixvec
cfixmat | itpp::operator+ (const cfixmat &a, const fixmat &b)
| cfixmat + fixmat
cfixmat | itpp::operator+ (const fixmat &a, const cfixmat &b)
| fixmat + cfixmat
cfixmat | itpp::operator- (const cfixmat &a, const fixmat &b)
| cfixmat - fixmat
cfixmat | itpp::operator- (const fixmat &a, const cfixmat &b)
| fixmat - cfixmat
cfixmat | itpp::operator* (const cfixmat &a, const fixmat &b)
| cfixmat * fixmat
cfixmat | itpp::operator* (const fixmat &a, const cfixmat &b)
| fixmat * cfixmat
cfixvec | itpp::operator+ (const cfixvec &a, const ivec &b)
| cfixvec + ivec
cfixvec | itpp::operator+ (const ivec &a, const cfixvec &b)
| ivec + cfixvec
cfixvec | itpp::operator- (const cfixvec &a, const ivec &b)
| cfixvec - ivec
cfixvec | itpp::operator- (const ivec &a, const cfixvec &b)
| ivec - cfixvec
CFix | itpp::operator* (const cfixvec &a, const ivec &b)
| cfixvec * ivec
CFix | itpp::operator* (const ivec &a, const cfixvec &b)
| ivec * cfixvec
cfixmat | itpp::operator+ (const cfixmat &a, const imat &b)
| cfixmat + imat
cfixmat | itpp::operator+ (const imat &a, const cfixmat &b)
| imat + cfixmat
cfixmat | itpp::operator- (const cfixmat &a, const imat &b)
| cfixmat - imat
cfixmat | itpp::operator- (const imat &a, const cfixmat &b)
| imat - cfixmat
cfixmat | itpp::operator* (const cfixmat &a, const imat &b)
| cfixmat * imat
cfixmat | itpp::operator* (const imat &a, const cfixmat &b)
| imat * cfixmat
void | itpp::Vec< Num_T >::set (const char *str)
| Set the vector equal to the values in the `str` string.
void | itpp::Mat< Num_T >::set (const char *str)
| Set matrix equal to values in the string `str`.

## Variables

const int | itpp::MAX_WORDLEN = 64
| Max word length.
const uint64_t | itpp::UINT64_POW2 [64]
| Table for fast multiplication or division by 2^n.
const double | itpp::DOUBLE_POW2 [128]
| Table for fast multiplication by 2^(n-64)

## Detailed Description

Fixed-Point Data Types.

Author
  Johan Bergman

# Contents

- Introduction
- Fix_Base
  - Shift factor
  - Word length
  - Sign encoding mode
  - Overflow mode
  - Quantization mode
  - Statistics object pointer
  - Output mode
- Fix and Fixed
- CFix and CFixed
- Fix_Factory
- Operators and methods
  - Initialization and assignment
  - Addition and subtraction
  - Multiplication and division
  - Bit-shifting
  - Conversion
  - Get data members
  - Input and output
- Functions
  - Function is_fix
  - Function set_fix
  - Functions lshift_fix and rshift_fix
  - Function assert_fixshift
  - Function unfix
  - Function to<T>
  - Other functions

# Introduction

How to include the support for fixed-point data types in your program:

#include <itpp/itbase.h>
#include <itpp/itfixed.h>
using namespace itpp;
itbase.h
Include file for the IT++ base module.
itfixed.h
Include file for the IT++ fixed-point module.
itpp
itpp namespace
Definition itmex.h:37

Fixed-point data types in IT++:

- itpp::Fix (real-valued, restrictions specified as constructor arguments)
- itpp::Fixed (real-valued, restrictions specified as template arguments)
- itpp::CFix (complex-valued, restrictions specified as constructor arguments)
- itpp::CFixed (complex-valued, restrictions specified as template arguments)

These classes have a common base class called Fix_Base; see inheritance diagram in the itpp::Fix_Base documentation. The following data members are inherited from Fix_Base:

- Shift factor
- Word length
- Sign encoding mode
- Overflow mode
- Quantization mode
- Statistics object pointer
- Output mode

The term "fixed-point restrictions" refers to all these data members except for the shift factor, which is considered to be part of the "fixed-point number". The shift factor has some resemblance to a binary point. The value of the shift factor is set in initializations and assignments and it is modified by multiplications, divisions and bit-shifting operations. The shift factor is used for checking that both terms have been shifted the same amount in additions and subtractions. Also, it is used to "un-shift" the data when a fixed-point number is converted to floating point.

Names of classes and enums have been aligned with the fixed-point data types in SystemC to some extent, but the fixed-point data types in IT++ and SystemC are quite different. In fact, the fixed-point data types in IT++ probably correspond better to the variable-precision integer types in SystemC (with one important difference: the fixed-point numbers in IT++ remember the amount of bit-shifting that has been applied to them, so that they can be converted back to "floating-point magnitude" easily if this is desired). The reason for this design choice in IT++ is to make the fixed-point simulations as fast as possible. If necessary, the core parts in itbase.h (e.g. Array, Vec and Mat) should be able to use some other data type than the ones presented here, assuming that a proper itpp::Factory is created for the data type, just like itpp::Fix_Factory has been created for these data types.

Sometimes the documentation for the IT++ fixed-point data types states that a function is "useful in templated code". This means that the function facilitates writing templated code where the template argument is meant to be either a floating-point type (double or complex<double>) or a fixed-point type (Fix or CFix), i.e. code which is supposed to support both floating-point and fixed-point simulations. For example, the operator >>= is defined for Fix and CFix, but not for double and complex<double>, so it might be a better idea to use the function rshift_fix which is defined for Fix and CFix as well as double and complex<double>.

For an example program, take a look at tests/fix_test.cpp.

# Fix_Base

## Shift factor

Supported shift factors: -64 ... +63 bit-shifts. 0 is default.

An IT++ fixed-point number consists of a bit representation and a shift factor. The shift factor is a member of Fix_Base, while the bit representation is a member of the inherited class (Fix or CFix). The shift factor indicates the number of bit-shifts that have been performed on the data. A positive shift factor means that the data has been left-shifted while a negative shift factor means that the data has been right-shifted. For information about how the shift factor is affected by different operators, see section Operators and methods.

## Word length

Supported word lengths: 1 ... 64 bits. 64 is default.

Warning
  Fix, Fixed, CFix and CFixed always use signed 64-bit integers to represent the fixed-point data. Therefore it is not recommended to declare variables with 64 bits and sign encoding mode US.

## Sign encoding mode

Supported sign encoding modes (itpp::e_mode):

- TC (Two's complement)
- US (Unsigned)

TC is default.

Warning
  Fix, Fixed, CFix and CFixed always use signed 64-bit integers to represent the fixed-point data. Therefore it is not recommended to declare variables with 64 bits and sign encoding mode US.

## Overflow mode

Supported overflow modes (itpp::o_mode):

- SAT (Saturation)
- WRAP (Wrap-around)

WRAP is default.

Note
  Fix, Fixed, CFix and CFixed apply this restriction during initialization and assignments only.

## Quantization mode

Supported quantization modes (itpp::q_mode), with definitions borrowed from SystemC (see SystemC documentation for further details):

- RND (Rounding to plus infinity): Add the most significant deleted bit to the remaining bits.
- RND_ZERO (Rounding to zero): If the most significant deleted bit is 1, and either the sign bit or at least one other deleted bit is 1, add 1 to the remaining bits.
- RND_MIN_INF (Rounding to minus infinity): If the most significant deleted bit is 1, and at least one other deleted bit is 1, add 1 to the remaining bits.
- RND_INF (Rounding to infinity): If the most significant deleted bit is 1, and either the inverted value of the sign bit or at least one other deleted bit is 1, add 1 to the remaining bits.
- RND_CONV (Convergent rounding with half-way value rounded to even value): If the most significant deleted bit is 1, and either the least significant of the remaining bits or at least one other deleted bit is 1, add 1 to the remaining bits.
- RND_CONV_ODD (Convergent rounding with half-way value rounded to odd value): If the most significant deleted bit is 1, and either the least significant of the remaining bits is 0 or at least one other deleted bit is 1, add 1 to the remaining bits (not defined in SystemC).
- TRN (Truncation): Just copy the remaining bits.
- TRN_ZERO (Truncation to zero): If the sign bit is 1, and either the most significant deleted bit or at least one other deleted bit is 1, add 1 to the remaining bits.

TRN is default. RND and TRN are usually the most implementation friendly. However, note that it is RND_INF that corresponds to "ordinary rounding" and TRN_ZERO that corresponds to "ordinary truncation".

Note
  Fix, Fixed, CFix and CFixed apply this restriction during initialization and right-shift operations only.

## Statistics object pointer

Supported statistics object pointer values: either a pointer to an itpp::Stat object or 0. 0 is default.

The sample method in the statistics object is called during initializations and assignments. A single statistics object can collect statistics from more than one fixed-point variable.

## Output mode

Supported output modes (itpp::output_mode), used by the output stream operator <<:

- OUTPUT_FIX: Output fixed-point representation only
- OUTPUT_FIX_SHIFT: Output fixed-point representation followed by <shift>
- OUTPUT_FLOAT: Output floating-point value
- OUTPUT_FLOAT_SHIFT: Output floating-point value followed by <<shift

OUTPUT_FIX_SHIFT is default. Unlike the other modes, output_mode is a static data member of Fix_Base, i.e. the output_mode is common for all fixed-point variables. Use the following commands to change output_mode:

Fix_Base::set_output_mode(OUTPUT_FIX);
Fix_Base::set_output_mode(OUTPUT_FIX_SHIFT);
Fix_Base::set_output_mode(OUTPUT_FLOAT);
Fix_Base::set_output_mode(OUTPUT_FLOAT_SHIFT);
// Alternative using a string parameter
Fix_Base::set_output_mode("OUTPUT_FIX");
Fix_Base::set_output_mode("OUTPUT_FIX_SHIFT");
Fix_Base::set_output_mode("OUTPUT_FLOAT");
Fix_Base::set_output_mode("OUTPUT_FLOAT_SHIFT");
// Alternative using an ostream modifier
cout << OUTPUT_FIX;
cout << OUTPUT_FIX_SHIFT;
cout << OUTPUT_FLOAT;
cout << OUTPUT_FLOAT_SHIFT;
itpp::Fix_Base::set_output_mode
static void set_output_mode(output_mode o)
Set output mode to OUTPUT_FIX, OUTPUT_FIX_SHIFT, OUTPUT_FLOAT or OUTPUT_FLOAT_SHIFT....
Definition fix_base.h:996
itpp::OUTPUT_FIX
@ OUTPUT_FIX
Output fixed-point representation only.
Definition fix_base.h:970
itpp::OUTPUT_FLOAT
@ OUTPUT_FLOAT
Output floating-point value.
Definition fix_base.h:972
itpp::OUTPUT_FIX_SHIFT
@ OUTPUT_FIX_SHIFT
Output fixed-point representation followed by <shift> (default)
Definition fix_base.h:971
itpp::OUTPUT_FLOAT_SHIFT
@ OUTPUT_FLOAT_SHIFT
Output floating-point value followed by <<shift.
Definition fix_base.h:973

# Fix and Fixed

Fix and Fixed are real-valued fixed-point data types primarily intended to replace `double` when a design is refined from floating- to fixed-point implementation. The data is stored in the least significant bits of a 64-bit integer variable.

The following example shows how to declare a two's complement (i.e. a signed) 20-bit variable with wrap-around as overflow handling with the initial value 3.14 shifted up 10 bits:

Fix a(3.14, 10, 20, TC, WRAP);
Fixed<20, TC, WRAP> b(3.14, 10);
itpp::Array
General array class.
Definition array.h:105
itpp::Fix
Fixed-point data type.
Definition fix.h:52
itpp::WRAP
@ WRAP
Wrap-around.
Definition fix_base.h:952
itpp::TC
@ TC
Two's complement.
Definition fix_base.h:943

Note that Fix takes the initial values as well as the fixed-point restrictions as constructor arguments. Fixed also takes the initial values as constructor arguments but it takes the fixed-point restrictions as template arguments. Choose Fix or Fixed depending on your needs. There are three main reasons why you would want to choose Fix instead of Fixed. First, if you want to change the fixed-point restrictions for a variable during run time, you have to use Fix, since the fixed-point restrictions for Fixed have been "fixed" at compile time. Second, if your code is using a lot of templating, you might end up with many more template arguments if you use Fixed than you would if you use Fix, since each set of fixed-point restrictions that you want to use will correspond to another type (based on the class template Fixed) instead of just different configurations of a single type (Fix). Third, the vector and matrix operations currently work better for Fix than for Fixed.

Note
  Fixed is derived from Fix, which means that operators, methods and functions for Fix can be used for Fixed as well. However, the functions for Vec<Fix> (fixvec) and Mat<Fix> (fixmat) cannot be used for Vec<Fixed> and Mat<Fixed>.

If you choose Fix, you should also read the section Fix_Factory. If you choose Fixed, you may find it convenient to use the following typedefs:

typedef Fixed<1, TC, WRAP> fixed1; // for Fixed with 1 bit
...
typedef Fixed<64, TC, WRAP> fixed64; // for Fixed with 64 bits
typedef Fixed<1, US, WRAP> ufixed1; // for Unsigned Fixed with 1 bit
...
typedef Fixed<64, US, WRAP> ufixed64; // for Unsigned Fixed with 64 bits
typedef Fixed<1, TC, SAT> sfixed1; // for Saturated Fixed with 1 bit
...
typedef Fixed<64, TC, SAT> sfixed64; // for Saturated Fixed with 64 bits
typedef Fixed<1, US, SAT> sufixed1; // for Saturated Unsigned Fixed with 1 bit
...
typedef Fixed<64, US, SAT> sufixed64; // for Saturated Unsigned Fixed with 64 bits
itpp::sfixed1
Fixed< 1, TC, SAT > sfixed1
Typedefs for saturated Fixed (sfixed1, sfixed2, ..., sfixed64)
Definition fixed.h:217
itpp::fixed1
Fixed< 1, TC, WRAP > fixed1
Typedefs for Fixed (fixed1, fixed2, ..., fixed64)
Definition fixed.h:81
itpp::ufixed1
Fixed< 1, US, WRAP > ufixed1
Typedefs for unsigned Fixed (ufixed1, ufixed2, ..., ufixed64)
Definition fixed.h:149
itpp::sufixed1
Fixed< 1, US, SAT > sufixed1
Typedefs for saturated unsigned Fixed (sufixed1, sufixed2, ..., sufixed64)
Definition fixed.h:285

Note
  These typedefs use the default values for quantization mode (TRN) and statistics object pointer value (0). Also note that U stands for Unsigned but S stands for Saturated, NOT for Signed.

Declaration corresponding to the above Fixed example but using one of the typedefs:

fixed20 b(3.14, 10);

# CFix and CFixed

CFix and CFixed are complex-valued fixed-point data types primarily intended to replace `complex<double>` when a design is refined from floating- to fixed-point implementation. The data is stored in the least significant bits of two 64-bit integer variables: one for the real part and one for the imaginary part. The two parts have a common shift factor (the one inherited from Fix_Base), so it is not possible to shift only one of them.

The following example shows two ways to declare a two's complement (i.e. a signed) 20-bit variable with wrap-around as overflow handling with the initial value 1.11 + 2.22i shifted up 10 bits:

CFix a(1.11, 2.22, 10, 20, TC, WRAP);
CFixed<20, TC, WRAP> b(1.11, 2.22, 10);
CFix c(complex<double>(1.11, 2.22), 0.0, 10, 20, TC, WRAP);
CFixed<20, TC, WRAP> d(complex<double>(1.11, 2.22), 0.0, 10);
itpp::CFix
Complex fixed-point data type.
Definition cfix.h:52

Note
  The shift factor is passed as the third argument to the CFix/CFixed constructors. If the first argument is complex, the second argument is a dummy (that was set to 0.0 in the examples above).

Choose CFix or CFixed depending on your needs; see section Fix and Fixed. If you choose CFix, you should also read the section Fix_Factory.

Note
  CFixed is derived from CFix, which means that operators, methods and functions for CFix can be used for CFixed as well. However, the functions for Vec<CFix> (cfixvec) and Mat<CFix> (cfixmat) cannot be used for Vec<CFixed> and Mat<CFixed>.

If you choose CFixed, you may find it convenient to use the following typedefs, which are predefined in IT++:

typedef CFixed<1, TC, WRAP> cfixed1; // for CFixed with 1 bit
...
typedef CFixed<64, TC, WRAP> cfixed64; // for CFixed with 64 bits
typedef CFixed<1, TC, SAT> scfixed1; // for Saturated CFixed with 1 bit
...
typedef CFixed<64, TC, SAT> scfixed64; // for Saturated CFixed with 64 bits
itpp::cfixed1
CFixed< 1, TC, WRAP > cfixed1
Typedefs for CFixed (cfixed1, cfixed2, ..., cfixed64)
Definition cfixed.h:105

Note
  These typedefs use the default values for sign encoding mode (TC), quantization mode (TRN) and statistics object pointer value (0). Also note that S stands for Saturated, NOT for Signed.

Declarations corresponding to the above CFixed examples but using one of the typedefs:

cfixed20 b(1.11, 2.22, 10);
cfixed20 d(complex<double>(1.11, 2.22), 0.0, 10);

# Fix_Factory

IF you choose to use Fix/CFix (instead of Fixed/CFixed) AND you want to declare an Array/Vec/Mat with Fix/CFix elements AND you wish to specify some non-default fixed-point restrictions for these elements (i.e. something else than 64-bit word length, two's complement as sign encoding mode, wrap-around as overflow mode, truncation as quantization mode, and no statistics object), THEN you will need to use a Fix_Factory when declaring the Array/Vec/Mat of Fix/CFix. Here is how it works, somewhat simplified: you give the fixed-point restrictions as parameters to the Fix_Factory, then you give the Fix_Factory as a parameter to the Array/Vec/Mat, and finally the Array/Vec/Mat uses the Fix_Factory to create Fix/CFix elements with those fixed-point restrictions. All constructors for Array, Vec and Mat can take a Fix_Factory (or any other Factory for that matter) as their last, optional argument. It is assumed that all elements in the Array/Vec/Mat should have the same fixed-point restrictions (and use a common statistics object, if any). Note that a Fix_Factory can create both Fix and CFix objects. For information on Factory in general and Fix_Factory in particular, see the Detailed Descriptions for itpp::Factory and itpp::Fix_Factory, respectively.

The following example shows how to declare a vector of length 7 with Fix elements that are two's complement 20-bit variables with wrap-around as overflow handling:

Vec<Fix> a(7, FIX20);

FIX20 is one of many predefined Fix_Factory; see the Detailed Description for itpp::Fix_Factory.

Note
  One might wonder why the Array/Vec/Mat classes themselves cannot take the fixed-point restrictions as parameters directly and create the Fix/CFix elements without help from a Fix_Factory. The main benefit with the chosen solution is that the Array/Vec/Mat classes are not "contaminated" with knowledge (parameters, methods, etc) that is specific to the Fix/CFix types. If the user for some reason prefers to use some other type (i.e. a type not known by IT++) as the Array/Vec/Mat element type, this should work fine as long as he or she creates a corresponding Factory. And this is exactly the way that Fix/CFix and Fix_Factory work.

Fix/CFix should not need to know about Fix_Factory, but for the sake of uniform syntax in declarations, an exception has been made:

Fix a(FIX20);

i.e. a Fix/CFix declaration can take a Fix_Factory as an argument, just like the Vec<Fix> declaration above did.

Note
  All declarations with a Fix_Factory as a constructor argument also work in templated code; see the Detailed Description for itpp::Fix_Factory.

# Operators and methods

## Initialization and assignment

Fixed-point variables can be initialized with a fixed- or a floating-point value:

// Initialize a with the floating-point value double(3.14*pow2(10))
// and word length 20, two's complement, wrap-around and rounding
Fix a(3.14, 10, 20, TC, WRAP, RND);
// Initialize b with the fixed-point value a
// and word length 7, two's complement, wrap-around and rounding
Fix b(a, 7, TC, WRAP, RND);
itpp::RND
@ RND
Rounding to plus infinity.
Definition fix_base.h:958

In this example, `b` was initialized with the same value as `a` but with smaller word length resulting in overflow, since round(3.14*pow2(10)) does not fit in the 7-bit variable `b`.

Warning
  All fixed-point data types have default constructors. For Fix/CFix, the default constructor gives full word length (64 bits). If you call templated functions with Fix/CFix as the template argument, they might use these default constructors for declaration of temporary variables, which may then contain unrestricted (64-bit) temporary results. If you want these temporary results to be restricted, then you may have to modify the function to introduce fixed-point restrictions for the temporary results, and even introduce new temporary variables in order to avoid more than one operation per expression (demonstrated in an example below). For Fixed/CFixed, on the other hand, the default constructor gives certain fixed-point restrictions, but note that it may still be necessary to introduce other fixed-point restrictions as well as new temporary variables in the function.

The assignment operators =, +=, -=, *=, /=, <<= and >>= are supported. For =, +=, -=, *= and /=, the right-hand operand can be another fixed-point variable or an integer value. If it is an integer value, it is interpreted as a fixed-point value with shift factor 0. The = operator simply copies the shift factor from the right side to the left side. For information on how the other operators treat the shift factor, see sections Addition and subtraction, Multiplication and division and Bit-shifting.

If assignment to a scaled `double` is desired (when initialization has already taken place), the itpp::Fix::set method can be used.

// Initialize c with the floating-point value double(3.14*pow2(10))
// The shift factor is set to 10
Fix c(3.14, 10);
// Set c equal to 123. The shift factor is set to 0
// Note that the old shift factor 10 is discarded
c = 123;
// Set c equal to the integer portion of double(3.14*pow2(10))
// The shift factor is set to 10 (again)
c.set(3.14, 10);
// Achieve the same result using a temporary variable
// Note that the assignment operator copies the shift factor
c = Fix(3.14, 10);

When the floating-point value is quantized, the quantization mode of the fixed-point variable (TRN in the example above, since `c` has this quantization mode) will be used, unless some other quantization mode (e.g. RND) is specified as a third argument to set:

c.set(3.14, 10, RND);

Note
  If you write templated code, you are better off if you use the set_fix function described in section Function set_fix instead of the set method.

There are also methods for setting data representation and shift directly: itpp::Fix::set_re, itpp::CFix::set_im and itpp::Fix_Base::set_shift. They are mainly intended for internal use.

## Addition and subtraction

Addition and subtraction between two fixed-point variables as well as between a fixed-point variable and an integer variable is supported. The unary minus operator is also defined. For Fix and CFix, several vector and matrix operations are also supported.

// Declare a fixed-point vector with 7 elements
// (using the predefined Fix_Factory FIX20)
Vec<Fix> d(7, FIX20);
// Set all 7 elements equal to 77 with shift factor 0
d = Fix(77);
// Declare an integer vector with 7 elements
ivec e = "1 2 3 4 5 6 7";
// Add fixed-point vector d and integer vector e. Both have shift factor 0
Vec<Fix> f(d + e, FIX20);

Note
  The addition and subtraction operators require that both operands have the same shift factor, unless at least one of the operands is zero. If `d` had been assigned with a different shift factor than 0 in the above example (and ASSERT_LEVEL > 0), the addition `d + e` would have failed, resulting in termination with the error message "assert_shifts: Different shifts not allowed!".

As hinted earlier, the fixed-point restrictions are applied during initialization, assignment and bit-shifting operations only. This means that the result of an addition or subtraction is unrestricted (64 bits).

Fix g(0, 0, 8, TC, SAT);
Fix h(100, 0, 8, TC, SAT);
Fix i(100, 0, 8, TC, SAT);
Fix j(-100, 0, 8, TC, SAT);
// The result of h + i is unrestricted (64 bits) but when it is assigned to g,
// it is restricted according to the fixed-point restrictions of g (8 bits).
// We get overflow, since 100+100=200 doesn't fit in an 8-bit signed variable.
// The saturated result will be 127
g = h + i;
// But now we don't get overflow since 100+100-100=100 does fit!
g = h + i + j;
// If we do want the temporary result to be restricted, we have to make
// an explicit temporary variable (with appropriate restrictions) for it
Fix tmp(0, 0, 8, TC, SAT);
// The first sum will be saturated to 127
tmp = h + i;
// The final sum will be 127-100=27, i.e. we got a different
// result when we introduced a restricted temporary variable
g = tmp + j;
itpp::SAT
@ SAT
Saturation.
Definition fix_base.h:949

## Multiplication and division

Multiplication and division between two fixed-point variables as well as between a fixed-point variable and an integer variable is supported. For Fix and CFix, several vector and matrix operations are also supported.

As stated earlier, the fixed-point restrictions are applied during initialization, assignment and bit-shifting operations only. This means that the result of a multiplication or division is unrestricted (64 bits) in the same way as for an addition or subtraction; see section Addition and subtraction.

The resulting shift factor after a multiplication is the sum of the two shift factors, while the resulting shift factor after a division is the difference between the numerator shift factor and the denominator shift factor. The result of a division is always quantized using truncation, i.e. the quantization modes of the involved fixed-point variables do not matter. Note that sometimes divisions can be replaced with multiplications and/or bit-shifting operations; see section Bit-shifting.

Warning
  Complex multiplications and divisions are supported, but they utilize temporary variables with full word length (64 bits).

## Bit-shifting

The <<= and >>= operators are defined for the fixed-point data types. As an alternative, you can use the itpp::Fix::lshift and itpp::Fix::rshift methods. The appropriate fixed-point restrictions of the variable are applied, i.e. for left-shifting the overflow mode is applied and for right-shifting the quantization mode is applied. There is also a version of rshift that takes a quantization mode as the last argument (but there is no corresponding version of the >>= operator since it cannot take an extra argument).

// Declare a fixed-point variable with the default quantization mode (TRN)
Fix a(3.14, 10);
// Right shift 5 bits using the quantization mode of a (i.e. TRN)
a.rshift(5);
// Right shift 5 bits using the specified quantization mode (i.e. RND)
a.rshift(5, RND);

Note
  If you write templated code, you are better off if you use the lshift_fix and rshift_fix functions described in section Functions lshift_fix and rshift_fix instead of the <<= and >>= operators and the lshift and rshift methods.

The << and >> operators are not defined for the fixed-point data types since it is not clear what quantization mode that should be applied for the >> operator.

## Conversion

Fix and Fixed can be converted to double, while CFix and CFixed can be converted to complex<double>. The conversion operators "un-shift" the data by multiplying the fixed-point bit representation with pow2(-shift).

The itpp::Fix::unfix and itpp::CFix::unfix methods can always be used:

Fix a(3.14, 5);
cout << a.unfix() << endl;

The resulting output is 3.125.

Note
  If you write templated code, you are better off if you use the functions unfix or to<T> described in sections Function unfix and Function to<T> instead of the unfix method.

Equivalently, the double(Fix&) and complex<double>(CFix&) operators can be used, unless you define NO_IMPLICIT_FIX_CONVERSION before you include IT++ in your program.

Fix a(3.14, 5);
cout << double(a) << endl;

The resulting output is 3.125.

Finally, Fix/Fixed can be converted to CFix/CFixed using the appropriate CFix/CFixed constructors.

## Get data members

This example shows how to get the data members of fixed-point variables:

Fix a;
int64_t the_bit_representation = a.get_re();
int the_shift_factor = a.get_shift();
int the_word_length = a.get_wordlen();
e_mode the_sign_encoding_mode = a.get_e_mode();
o_mode the_overflow_mode = a.get_o_mode();
q_mode the_quantization_mode = a.get_q_mode();
int64_t max_bit_representation = a.get_max();
int64_t min_bit_representation = a.get_min();
itpp::o_mode
o_mode
Overflow modes (aligned with SystemC)
Definition fix_base.h:948
itpp::e_mode
e_mode
Sign encoding modes (aligned with SystemC)
Definition fix_base.h:942
itpp::q_mode
q_mode
Quantization modes (aligned with SystemC)
Definition fix_base.h:957

Note
  For CFix and CFixed, you get the bit representation for the imaginary part with the method get_im().

## Input and output

The print() method outputs the entire state; see section Get data members.

Fix a;
a.print();

This code example shows how to input and output fixed-point numbers:

CFix a(FIX8);
a.set(0.0, 0.0, 4);
cout << "Old a: " << a << endl;
cout << "New a? ";
cin >> a;
cout << "New a: " << a << endl;

Complex numbers can be input on both the C++ form and the IT++ form:

Old a: 0+0i<4>
New a? 1+2i
New a: 1+2i<4>
Old a: 0+0i<4>
New a? (1,2)
New a: 1+2i<4>

Note
  The output_mode is OUTPUT_FIX_SHIFT in these examples; see section Output mode.

In the above examples, only the data representation was changed, while the shift (4) was kept. It is however possible to enter another (positive or negative) shift factor as well:

Old a: 0+0i<4>
New a? 1+2i<5>
New a: 1+2i<5>

It is also possible to enter a floating-point value and a (positive or negative) shift, rather than the data representation and a shift, if a slightly different format is used:

Old a: 0+0i<4>
New a? 1+2i<<5
New a: 32+64i<5>

The resulting data representation is the entered floating-point value 1+2i multiplied by 2^5.

Note
  In order to enter a negative shift, write 1+2i<<-5. It is not possible to write 1+2i>>5.

Vectors and matrices support the same formats for fixed-point numbers. However, all old elements are assumed to have the same shift factor, and the shift factor of the first old element becomes the default shift factor for all elements of the vector or matrix. The same holds in e.g. an Array of vectors, i.e. the shift factor of the first old element in each vector becomes the default shift factor for all elements of that vector. The default shift factor in an empty vector or matrix is zero.

# Functions

## Function is_fix

The function itpp::is_fix returns true only if the argument is of type Fix or CFix or an Array/Vec/Mat of Fix or CFix.

Array<Array<Vec<Fix> > > aavf(FIX20);
bool will_be_true = is_fix(aavf);
itpp::is_fix
bool is_fix(const T &)
Return true only if argument is of type Fix or CFix (or an Array/Vec/Mat of Fix or CFix)
Definition fix_functions.h:48

Warning
  Unfortunately, the function is_fix returns false if the argument is of type Fixed or CFixed.

## Function set_fix

The function itpp::set_fix sets `y = x * pow2(n)` if the first argument is of type Fix or CFix or an Array/Vec/Mat of Fix or CFix. If the first argument is of type double or complex<double> or an Array/Vec/Mat of double or complex<double>, the function just sets `y = x`.

Fix fix_var(FIX20);
set_fix(fix_var, 3.14, 10);
// fix_var will equal the integer portion of 3.14 * pow2(10)
double double_var(FIX20);
set_fix(double_var, 3.14, 10);
// double_var will just equal 3.14
itpp::set_fix
void set_fix(Fix &y, double x, int n)
Set y = x * pow2(n) using the quantization mode of y.
Definition fix_functions.h:65

When the floating-point value is quantized, the quantization mode of the first argument (TRN in the example above, since fix_var has this quantization mode) will be used, unless some other quantization mode (e.g. RND) is specified as a fourth argument to set_fix:

set_fix(fix_var, 3.14, 10, RND);

## Functions lshift_fix and rshift_fix

The functions itpp::lshift_fix and itpp::rshift_fix perform left and right bit-shifts, respectively, if the first argument is of type Fix or CFix or an Array/Vec/Mat of Fix or CFix. If the first argument is of type double or complex<double> or an Array/Vec/Mat of double or complex<double>, the functions do not do anything at all.

// This will right-shift fix_var 10 bits
rshift_fix(fix_var, 10);
// This will not affect double_var
rshift_fix(double_var, 10);
itpp::rshift_fix
void rshift_fix(Fix &y, int n)
Right shift n bits using the quantization mode of y.
Definition fix_functions.h:220

When a fixed-point value is right-shifted using rshift_fix, the quantization mode of the first argument (TRN in the example above, since fix_var has this quantization mode) will be used, unless some other quantization mode (e.g. RND) is specified as a third argument to rshift_fix:

rshift_fix(fix_var, 10, RND);

When a fixed-point value is left-shifted using lshift_fix, on the other hand, the overflow mode of the first argument is always used.

## Function assert_fixshift

The itpp::assert_fixshift function can be used to verify that the shift factor has the expected value:

Fix a(3.14, 5);
// We will pass this check since 5 = 5
assert_fixshift(a, 5);
// The program will terminate (if ASSERT_LEVEL > 0) since 5 != 6
assert_fixshift(a, 6);
itpp::assert_fixshift
void assert_fixshift(double, int)
If x is a fixed-point variable, assert that x has the specified shift value, otherwise do nothing.
Definition fix_functions.h:312

If the first argument is of type double or complex<double> instead, no test will be performed (since they have no shift factors).

## Function unfix

The itpp::unfix function converts a fixed-point variable to a floating-point variable (or an Array/Vec/Mat of fixed-point variables to an Array/Vec/Mat of floating-point variables) by multiplying the fixed-point bit representation with pow2(-shift), using the unfix method mentioned above.

Fix a(3.14, 5);
double b = unfix(a);
Array<Mat<CFix> > c(FIX40);
cin >> c;
Array<cmat> d = unfix(c);
itpp::unfix
double unfix(const Fix &x)
Convert Fix to double by multiplying the bit representation with pow2(-shift)
Definition fix_functions.h:463

If the argument is a floating-point variable (or an Array/Vec/Mat of floating-point variables) instead, the function just returns the argument.

## Function to<T>

The itpp::to<T> function is a very general conversion function. It converts a floating- or fixed-point variable to a floating- or fixed-point variable (or a floating- or fixed-point Array/Vec/Mat to a floating- or fixed-point Array/Vec/Mat) depending on the types of the argument and of the specified template parameter.

// Convert a Vec<double> to a Vec<Fix> and assign it to f
Vec<double> e = "1.0 2.0 3.0";
Vec<Fix> f;
f = to<Fix>(e); // convert e "to Fix"
// Convert an Array<Array<Mat<Fix> > > called g to
// an Array<Array<Mat<CFix> > > and assign it to h
Array<Array<Mat<CFix> > > h;
h = to<CFix>(g); // convert g "to CFix"
itpp::to< CFix >
cfixvec to< CFix >(const cfixvec &x)
Convert cfixvec to cfixvec.
Definition fix_functions.h:393
itpp::to< Fix >
fixvec to< Fix >(const fixvec &x)
Convert fixvec to fixvec.
Definition fix_functions.h:391

Note
  The variants to<double>(x) and to<complex<double> >(x) provide the same functionality as unfix(x).

Warning
  Be aware that the variants to<Fix>(x) and to<CFix>(x) will return a fixed-point variable with the shift factor(s) set to zero if x is a floating-point variable. However, if x is a fixed-point variable, the shift will be copied to the return variable.

## Other functions

- itpp::abs
- itpp::real
- itpp::imag
- itpp::conj

## Typedef Documentation

## cfixvec

typedef Vec<CFix> itpp::cfixvec

Typedef for complex fixed-point vector type.

Definition at line 178 of file cfix.h.

## cfixmat

typedef Mat<CFix> itpp::cfixmat

Typedef for complex fixed-point matrix type.

Definition at line 180 of file cfix.h.

## fixvec

typedef Vec<Fix> itpp::fixvec

Typedef for fixed-point vector type.

Definition at line 151 of file fix.h.

## fixmat

typedef Mat<Fix> itpp::fixmat

Typedef for fixed-point matrix type.

Definition at line 153 of file fix.h.

## fixrep

typedef int64_t itpp::fixrep

Representation for fixed-point data types.

Definition at line 884 of file fix_base.h.

## Enumeration Type Documentation

## e_mode

enum itpp::e_mode

Sign encoding modes (aligned with SystemC)

Enumerator
TC | Two's complement.
US | Unsigned.

Definition at line 942 of file fix_base.h.

## o_mode

enum itpp::o_mode

Overflow modes (aligned with SystemC)

Enumerator
SAT | Saturation.
SAT_ZERO | Saturation to zero (Not implemented)
SAT_SYM | Symmetrical saturation (Not implemented)
WRAP | Wrap-around.
WRAP_SM | Sign magnitued wrap-around (Not implemented)

Definition at line 948 of file fix_base.h.

## q_mode

enum itpp::q_mode

Quantization modes (aligned with SystemC)

Enumerator
RND | Rounding to plus infinity.
RND_ZERO | Rounding to zero.
RND_MIN_INF | Rounding to minus infinity.
RND_INF | Rounding to infinity.
RND_CONV | Convergent rounding with half-way value rounded to even value.
RND_CONV_ODD | Convergent rounding with half-way value rounded to odd value (not defined in SystemC)
TRN | Truncation.
TRN_ZERO | Truncation to zero.

Definition at line 957 of file fix_base.h.

## output_mode

enum itpp::output_mode

Output modes.

Enumerator
OUTPUT_FIX | Output fixed-point representation only.
OUTPUT_FIX_SHIFT | Output fixed-point representation followed by <shift> (default)
OUTPUT_FLOAT | Output floating-point value.
OUTPUT_FLOAT_SHIFT | Output floating-point value followed by <<shift.

Definition at line 969 of file fix_base.h.

## Function Documentation

## assert_shifts() [1/5]

ITPP_EXPORT int itpp::assert_shifts | ( | const CFix & | x,
|  | const CFix & | y
| ) |  |

Check that x.shift==y.shift OR x==0 OR y==0 and return the shift (for the non-zero argument)

Definition at line 249 of file cfix.cpp.

Referenced by itpp::operator+(), itpp::operator+(), itpp::operator+(), itpp::operator+(), itpp::operator+(), itpp::operator+(), itpp::operator+(), itpp::operator+(), itpp::operator-(), itpp::operator-(), itpp::operator-(), itpp::operator-(), itpp::operator-(), itpp::operator-(), itpp::operator-(), and itpp::operator-().

## assert_shifts() [2/5]

ITPP_EXPORT int itpp::assert_shifts | ( | const CFix & | x,
|  | const Fix & | y
| ) |  |

Check that x.shift==y.shift OR x==0 OR y==0 and return the shift (for the non-zero argument)

Definition at line 265 of file cfix.cpp.

## assert_shifts() [3/5]

ITPP_EXPORT int itpp::assert_shifts | ( | const CFix & | x,
|  | int | y
| ) |  |

Check that x.shift==0 OR x==0 OR y==0 and return x.shift.

Definition at line 281 of file cfix.cpp.

## operator>>() [1/2]

ITPP_EXPORT std::istream & itpp::operator>> | ( | std::istream & | is,
|  | CFix & | x
| ) |  |

Input bit representation and, optionally, the shift.

Definition at line 288 of file cfix.cpp.

References itpp::CFix::set(), itpp::CFix::set_im(), itpp::CFix::set_re(), and itpp::Fix_Base::set_shift().

## operator<<() [1/3]

ITPP_EXPORT std::ostream & itpp::operator<< | ( | std::ostream & | os,
|  | const CFix & | x
| ) |  |

Output bit representation and, optionally, the shift.

Definition at line 316 of file cfix.cpp.

References itpp::CFix::get_im(), itpp::Fix_Base::get_output_mode(), itpp::CFix::get_re(), itpp::Fix_Base::get_shift(), it_error, itpp::OUTPUT_FIX, itpp::OUTPUT_FIX_SHIFT, itpp::OUTPUT_FLOAT, and itpp::OUTPUT_FLOAT_SHIFT.

## assert_shifts() [4/5]

ITPP_EXPORT int itpp::assert_shifts | ( | const Fix & | x,
|  | const Fix & | y
| ) |  |

Check that x.shift==y.shift OR x==0 OR y==0 and return the shift (for the non-zero argument)

Definition at line 169 of file fix.cpp.

## assert_shifts() [5/5]

ITPP_EXPORT int itpp::assert_shifts | ( | const Fix & | x,
|  | int | y
| ) |  |

Check that x.shift==0 OR x==0 OR y==0 and return x.shift.

Definition at line 185 of file fix.cpp.

## operator>>() [2/2]

ITPP_EXPORT std::istream & itpp::operator>> | ( | std::istream & | is,
|  | Fix & | x
| ) |  |

Input bit representation and, optionally, the shift.

Definition at line 192 of file fix.cpp.

References itpp::Fix::set(), itpp::Fix::set_re(), and itpp::Fix_Base::set_shift().

## operator<<() [2/3]

ITPP_EXPORT std::ostream & itpp::operator<< | ( | std::ostream & | os,
|  | const Fix & | x
| ) |  |

Output bit representation and, optionally, the shift.

Definition at line 218 of file fix.cpp.

References itpp::Fix_Base::get_output_mode(), itpp::Fix::get_re(), itpp::Fix_Base::get_shift(), it_error, itpp::OUTPUT_FIX, itpp::OUTPUT_FIX_SHIFT, itpp::OUTPUT_FLOAT, and itpp::OUTPUT_FLOAT_SHIFT.

## operator<<() [3/3]

std::ostream & itpp::operator<< | ( | std::ostream & | os,
|  | const output_mode & | o
| ) |  |

inline

Set output mode.

Definition at line 1058 of file fix_base.h.

References itpp::Fix_Base::set_output_mode().

## create_elements< Fix >()

template<>

ITPP_EXPORT void itpp::create_elements< Fix > | ( | Fix *& | ptr,
|  | const int | n,
|  | const Factory & | f
| ) |  |

Create an n-length array of Fix using Fix_Factory `f`.

Definition at line 58 of file fix_factory.cpp.

## create_elements< CFix >()

template<>

ITPP_EXPORT void itpp::create_elements< CFix > | ( | CFix *& | ptr,
|  | const int | n,
|  | const Factory & | f
| ) |  |

Create an n-length array of CFix using Fix_Factory `f`.

Definition at line 76 of file fix_factory.cpp.

## is_fix() [1/8]

template<class T >

bool itpp::is_fix | ( | const T & |  | ) |

inline

Return true only if argument is of type Fix or CFix (or an Array/Vec/Mat of Fix or CFix)

Definition at line 48 of file fix_functions.h.

Referenced by itpp::is_fix().

## is_fix() [2/8]

template<>

bool itpp::is_fix | ( | const Fix & |  | ) |

inline

Return true only if argument is of type Fix or CFix (or an Array/Vec/Mat of Fix or CFix)

Definition at line 50 of file fix_functions.h.

## is_fix() [3/8]

template<>

bool itpp::is_fix | ( | const fixvec & |  | ) |

inline

Return true only if argument is of type Fix or CFix (or an Array/Vec/Mat of Fix or CFix)

Definition at line 52 of file fix_functions.h.

## is_fix() [4/8]

template<>

bool itpp::is_fix | ( | const fixmat & |  | ) |

inline

Return true only if argument is of type Fix or CFix (or an Array/Vec/Mat of Fix or CFix)

Definition at line 54 of file fix_functions.h.

## is_fix() [5/8]

template<>

bool itpp::is_fix | ( | const CFix & |  | ) |

inline

Return true only if argument is of type Fix or CFix (or an Array/Vec/Mat of Fix or CFix)

Definition at line 56 of file fix_functions.h.

## is_fix() [6/8]

template<>

bool itpp::is_fix | ( | const cfixvec & |  | ) |

inline

Return true only if argument is of type Fix or CFix (or an Array/Vec/Mat of Fix or CFix)

Definition at line 58 of file fix_functions.h.

## is_fix() [7/8]

template<>

bool itpp::is_fix | ( | const cfixmat & |  | ) |

inline

Return true only if argument is of type Fix or CFix (or an Array/Vec/Mat of Fix or CFix)

Definition at line 60 of file fix_functions.h.

## is_fix() [8/8]

template<class T >

bool itpp::is_fix | ( | const Array< T > & |  | ) |

inline

Return true only if argument is of type Fix or CFix (or an Array/Vec/Mat of Fix or CFix)

Definition at line 62 of file fix_functions.h.

References itpp::is_fix().

## set_fix() [1/40]

void itpp::set_fix | ( | Fix & | y,
|  | double | x,
|  | int | n
| ) |  |

inline

Set `y = x * pow2(n)` using the quantization mode of `y`.

Definition at line 65 of file fix_functions.h.

References itpp::Fix::set().

Referenced by itpp::set_fix(), itpp::set_fix(), itpp::set_fix(), and itpp::set_fix().

## set_fix() [2/40]

void itpp::set_fix | ( | Fix & | y,
|  | double | x,
|  | int | n,
|  | q_mode | q
| ) |  |

inline

Set `y = x * pow2(n)` using the specified quantization mode `q`.

Definition at line 67 of file fix_functions.h.

References itpp::Fix::set().

## set_fix() [3/40]

void itpp::set_fix | ( | fixvec & | y,
|  | const vec & | x,
|  | int | n
| ) |  |

inline

Set `y = x * pow2(n)` using the quantization mode of `y`.

Definition at line 69 of file fix_functions.h.

References itpp::Vec< Num_T >::set(), itpp::Vec< Num_T >::set_size(), and itpp::Vec< Num_T >::size().

## set_fix() [4/40]

void itpp::set_fix | ( | fixvec & | y,
|  | const vec & | x,
|  | int | n,
|  | q_mode | q
| ) |  |

inline

Set `y = x * pow2(n)` using the specified quantization mode `q`.

Definition at line 75 of file fix_functions.h.

References itpp::Vec< Num_T >::set(), itpp::Vec< Num_T >::set_size(), and itpp::Vec< Num_T >::size().

## set_fix() [5/40]

void itpp::set_fix | ( | fixmat & | y,
|  | const mat & | x,
|  | int | n
| ) |  |

inline

Set `y = x * pow2(n)` using the quantization mode of `y`.

Definition at line 81 of file fix_functions.h.

References itpp::Mat< Num_T >::set(), itpp::Mat< Num_T >::set_size(), and itpp::Mat< Num_T >::size().

## set_fix() [6/40]

void itpp::set_fix | ( | fixmat & | y,
|  | const mat & | x,
|  | int | n,
|  | q_mode | q
| ) |  |

inline

Set `y = x * pow2(n)` using the specified quantization mode `q`.

Definition at line 87 of file fix_functions.h.

References itpp::Mat< Num_T >::set(), itpp::Mat< Num_T >::set_size(), and itpp::Mat< Num_T >::size().

## set_fix() [7/40]

void itpp::set_fix | ( | double & | y,
|  | double | x,
|  | int |
| ) |  |

inline

Set `y = x`. Useful in templated code.

Definition at line 93 of file fix_functions.h.

## set_fix() [8/40]

void itpp::set_fix | ( | double & | y,
|  | double | x,
|  | int | ,
|  | q_mode |
| ) |  |

inline

Set `y = x`. Useful in templated code.

Definition at line 95 of file fix_functions.h.

## set_fix() [9/40]

void itpp::set_fix | ( | vec & | y,
|  | const vec & | x,
|  | int |
| ) |  |

inline

Set `y = x`. Useful in templated code.

Definition at line 97 of file fix_functions.h.

## set_fix() [10/40]

void itpp::set_fix | ( | vec & | y,
|  | const vec & | x,
|  | int | ,
|  | q_mode |
| ) |  |

inline

Set `y = x`. Useful in templated code.

Definition at line 99 of file fix_functions.h.

## set_fix() [11/40]

void itpp::set_fix | ( | mat & | y,
|  | const mat & | x,
|  | int |
| ) |  |

inline

Set `y = x`. Useful in templated code.

Definition at line 101 of file fix_functions.h.

## set_fix() [12/40]

void itpp::set_fix | ( | mat & | y,
|  | const mat & | x,
|  | int | ,
|  | q_mode |
| ) |  |

inline

Set `y = x`. Useful in templated code.

Definition at line 103 of file fix_functions.h.

## set_fix() [13/40]

void itpp::set_fix | ( | CFix & | y,
|  | std::complex< double > | x,
|  | int | n
| ) |  |

inline

Set `y = x * pow2(n)` using the quantization mode of `y`.

Definition at line 106 of file fix_functions.h.

References itpp::CFix::set().

## set_fix() [14/40]

void itpp::set_fix | ( | CFix & | y,
|  | double | real,
|  | double | imag,
|  | int | n
| ) |  |

inline

Set `y = (real + i*imag) * pow2(n)` using the quantization mode of `y`.

Definition at line 108 of file fix_functions.h.

References itpp::imag(), itpp::real(), and itpp::CFix::set().

## set_fix() [15/40]

void itpp::set_fix | ( | CFix & | y,
|  | std::complex< double > | x,
|  | int | n,
|  | q_mode | q
| ) |  |

inline

Set `y = x * pow2(n)` using the specified quantization mode `q`.

Definition at line 110 of file fix_functions.h.

References itpp::CFix::set().

## set_fix() [16/40]

void itpp::set_fix | ( | CFix & | y,
|  | double | real,
|  | double | imag,
|  | int | n,
|  | q_mode | q
| ) |  |

inline

Set `y = (real + i*imag) * pow2(n)` using the specified quantization mode `q`.

Definition at line 112 of file fix_functions.h.

References itpp::imag(), itpp::real(), and itpp::CFix::set().

## set_fix() [17/40]

void itpp::set_fix | ( | cfixvec & | y,
|  | const cvec & | x,
|  | int | n
| ) |  |

inline

Set `y = x * pow2(n)` using the quantization mode of `y`.

Definition at line 114 of file fix_functions.h.

References itpp::Vec< Num_T >::set(), itpp::Vec< Num_T >::set_size(), and itpp::Vec< Num_T >::size().

## set_fix() [18/40]

void itpp::set_fix | ( | cfixvec & | y,
|  | const vec & | real,
|  | const vec & | imag,
|  | int | n
| ) |  |

inline

Set `y = (real + i*imag) * pow2(n)` using the quantization mode of `y`.

Definition at line 120 of file fix_functions.h.

References itpp::imag(), it_assert_debug, itpp::real(), itpp::Vec< Num_T >::set(), itpp::Vec< Num_T >::set_size(), and itpp::Vec< Num_T >::size().

## set_fix() [19/40]

void itpp::set_fix | ( | cfixvec & | y,
|  | const cvec & | x,
|  | int | n,
|  | q_mode | q
| ) |  |

inline

Set `y = x * pow2(n)` using the specified quantization mode `q`.

Definition at line 127 of file fix_functions.h.

References itpp::Vec< Num_T >::set(), itpp::Vec< Num_T >::set_size(), and itpp::Vec< Num_T >::size().

## set_fix() [20/40]

void itpp::set_fix | ( | cfixvec & | y,
|  | const vec & | real,
|  | const vec & | imag,
|  | int | n,
|  | q_mode | q
| ) |  |

inline

Set `y = (real + i*imag) * pow2(n)` using the specified quantization mode `q`.

Definition at line 133 of file fix_functions.h.

References itpp::imag(), it_assert_debug, itpp::real(), itpp::Vec< Num_T >::set(), itpp::Vec< Num_T >::set_size(), and itpp::Vec< Num_T >::size().

## set_fix() [21/40]

void itpp::set_fix | ( | cfixmat & | y,
|  | const cmat & | x,
|  | int | n
| ) |  |

inline

Set `y = x * pow2(n)` using the quantization mode of `y`.

Definition at line 140 of file fix_functions.h.

References itpp::Mat< Num_T >::set(), itpp::Mat< Num_T >::set_size(), and itpp::Mat< Num_T >::size().

## set_fix() [22/40]

void itpp::set_fix | ( | cfixmat & | y,
|  | const mat & | real,
|  | const mat & | imag,
|  | int | n
| ) |  |

inline

Set `y = (real + i*imag) * pow2(n)` using the quantization mode of `y`.

Definition at line 146 of file fix_functions.h.

References itpp::imag(), it_assert_debug, itpp::real(), itpp::Mat< Num_T >::set(), itpp::Mat< Num_T >::set_size(), and itpp::Mat< Num_T >::size().

## set_fix() [23/40]

void itpp::set_fix | ( | cfixmat & | y,
|  | const cmat & | x,
|  | int | n,
|  | q_mode | q
| ) |  |

inline

Set `y = x * pow2(n)` using the specified quantization mode `q`.

Definition at line 153 of file fix_functions.h.

References itpp::Mat< Num_T >::set(), itpp::Mat< Num_T >::set_size(), and itpp::Mat< Num_T >::size().

## set_fix() [24/40]

void itpp::set_fix | ( | cfixmat & | y,
|  | const mat & | real,
|  | const mat & | imag,
|  | int | n,
|  | q_mode | q
| ) |  |

inline

Set `y = (real + i*imag) * pow2(n)` using the specified quantization mode `q`.

Definition at line 159 of file fix_functions.h.

References itpp::imag(), it_assert_debug, itpp::real(), itpp::Mat< Num_T >::set(), itpp::Mat< Num_T >::set_size(), and itpp::Mat< Num_T >::size().

## set_fix() [25/40]

void itpp::set_fix | ( | std::complex< double > & | y,
|  | const std::complex< double > & | x,
|  | int |
| ) |  |

inline

Set `y = x`. Useful in templated code.

Definition at line 166 of file fix_functions.h.

## set_fix() [26/40]

void itpp::set_fix | ( | std::complex< double > & | y,
|  | double | real,
|  | double | imag,
|  | int |
| ) |  |

inline

Set `y = real + i*imag`. Useful in templated code.

Definition at line 168 of file fix_functions.h.

References itpp::imag(), and itpp::real().

## set_fix() [27/40]

void itpp::set_fix | ( | std::complex< double > & | y,
|  | const std::complex< double > & | x,
|  | int | ,
|  | q_mode |
| ) |  |

inline

Set `y = x`. Useful in templated code.

Definition at line 170 of file fix_functions.h.

## set_fix() [28/40]

void itpp::set_fix | ( | std::complex< double > & | y,
|  | double | real,
|  | double | imag,
|  | int | ,
|  | q_mode |
| ) |  |

inline

Set `y = real + i*imag`. Useful in templated code.

Definition at line 172 of file fix_functions.h.

References itpp::imag(), and itpp::real().

## set_fix() [29/40]

void itpp::set_fix | ( | cvec & | y,
|  | const cvec & | x,
|  | int |
| ) |  |

inline

Set `y = x`. Useful in templated code.

Definition at line 174 of file fix_functions.h.

## set_fix() [30/40]

void itpp::set_fix | ( | cvec & | y,
|  | const vec & | real,
|  | const vec & | imag,
|  | int |
| ) |  |

inline

Set `y = real + i*imag`. Useful in templated code.

Definition at line 176 of file fix_functions.h.

References itpp::imag(), itpp::real(), and itpp::to_cvec().

## set_fix() [31/40]

void itpp::set_fix | ( | cvec & | y,
|  | const cvec & | x,
|  | int | ,
|  | q_mode |
| ) |  |

inline

Set `y = x`. Useful in templated code.

Definition at line 178 of file fix_functions.h.

## set_fix() [32/40]

void itpp::set_fix | ( | cvec & | y,
|  | const vec & | real,
|  | const vec & | imag,
|  | int | ,
|  | q_mode |
| ) |  |

inline

Set `y = real + i*imag`. Useful in templated code.

Definition at line 180 of file fix_functions.h.

References itpp::imag(), itpp::real(), and itpp::to_cvec().

## set_fix() [33/40]

void itpp::set_fix | ( | cmat & | y,
|  | const cmat & | x,
|  | int |
| ) |  |

inline

Set `y = x`. Useful in templated code.

Definition at line 182 of file fix_functions.h.

## set_fix() [34/40]

void itpp::set_fix | ( | cmat & | y,
|  | const mat & | real,
|  | const mat & | imag,
|  | int |
| ) |  |

inline

Set `y = real + i*imag`. Useful in templated code.

Definition at line 184 of file fix_functions.h.

References itpp::imag(), itpp::real(), and itpp::to_cmat().

## set_fix() [35/40]

void itpp::set_fix | ( | cmat & | y,
|  | const cmat & | x,
|  | int | ,
|  | q_mode |
| ) |  |

inline

Set `y = x`. Useful in templated code.

Definition at line 186 of file fix_functions.h.

## set_fix() [36/40]

void itpp::set_fix | ( | cmat & | y,
|  | const mat & | real,
|  | const mat & | imag,
|  | int | ,
|  | q_mode |
| ) |  |

inline

Set `y = real + i*imag`. Useful in templated code.

Definition at line 188 of file fix_functions.h.

References itpp::imag(), itpp::real(), and itpp::to_cmat().

## set_fix() [37/40]

template<class T1 , class T2 >

void itpp::set_fix | ( | Array< T1 > & | y,
|  | const Array< T2 > & | x,
|  | int | n
| ) |  |

inline

Call set_fix for each Array element.

Definition at line 191 of file fix_functions.h.

References itpp::set_fix(), itpp::Array< T >::set_size(), and itpp::Array< T >::size().

## set_fix() [38/40]

template<class T1 , class T2 >

void itpp::set_fix | ( | Array< T1 > & | y,
|  | const Array< T2 > & | real,
|  | const Array< T2 > & | imag,
|  | int | n
| ) |  |

inline

Call set_fix for each Array element.

Definition at line 197 of file fix_functions.h.

References itpp::imag(), it_assert_debug, itpp::real(), itpp::set_fix(), itpp::Array< T >::set_size(), and itpp::Array< T >::size().

## set_fix() [39/40]

template<class T1 , class T2 >

void itpp::set_fix | ( | Array< T1 > & | y,
|  | const Array< T2 > & | x,
|  | int | n,
|  | q_mode | q
| ) |  |

inline

Call set_fix for each Array element.

Definition at line 204 of file fix_functions.h.

References itpp::set_fix(), itpp::Array< T >::set_size(), and itpp::Array< T >::size().

## set_fix() [40/40]

template<class T1 , class T2 >

void itpp::set_fix | ( | Array< T1 > & | y,
|  | const Array< T2 > & | real,
|  | const Array< T2 > & | imag,
|  | int | n,
|  | q_mode | q
| ) |  |

inline

Call set_fix for each Array element.

Definition at line 210 of file fix_functions.h.

References itpp::imag(), it_assert_debug, itpp::real(), itpp::set_fix(), itpp::Array< T >::set_size(), and itpp::Array< T >::size().

## lshift_fix() [1/13]

void itpp::lshift_fix | ( | Fix & | y,
|  | int | n
| ) |  |

inline

Left shift `n` bits.

Definition at line 218 of file fix_functions.h.

References itpp::Fix::lshift().

Referenced by itpp::lshift_fix().

## rshift_fix() [1/26]

void itpp::rshift_fix | ( | Fix & | y,
|  | int | n
| ) |  |

inline

Right shift `n` bits using the quantization mode of `y`.

Definition at line 220 of file fix_functions.h.

References itpp::Fix::rshift().

Referenced by itpp::rshift_fix(), and itpp::rshift_fix().

## rshift_fix() [2/26]

void itpp::rshift_fix | ( | Fix & | y,
|  | int | n,
|  | q_mode | q
| ) |  |

inline

Right shift `n` bits using the specified quantization mode `q`.

Definition at line 222 of file fix_functions.h.

References itpp::Fix::rshift().

## lshift_fix() [2/13]

void itpp::lshift_fix | ( | fixvec & | y,
|  | int | n
| ) |  |

inline

Left shift `n` bits.

Definition at line 224 of file fix_functions.h.

References itpp::Vec< Num_T >::size().

## rshift_fix() [3/26]

void itpp::rshift_fix | ( | fixvec & | y,
|  | int | n
| ) |  |

inline

Right shift `n` bits using the quantization mode of `y`.

Definition at line 227 of file fix_functions.h.

References itpp::Vec< Num_T >::size().

## rshift_fix() [4/26]

void itpp::rshift_fix | ( | fixvec & | y,
|  | int | n,
|  | q_mode | q
| ) |  |

inline

Right shift `n` bits using the specified quantization mode `q`.

Definition at line 230 of file fix_functions.h.

References itpp::Vec< Num_T >::size().

## lshift_fix() [3/13]

void itpp::lshift_fix | ( | fixmat & | y,
|  | int | n
| ) |  |

inline

Left shift `n` bits.

Definition at line 233 of file fix_functions.h.

References itpp::Mat< Num_T >::size().

## rshift_fix() [5/26]

void itpp::rshift_fix | ( | fixmat & | y,
|  | int | n
| ) |  |

inline

Right shift `n` bits using the quantization mode of `y`.

Definition at line 236 of file fix_functions.h.

References itpp::Mat< Num_T >::size().

## rshift_fix() [6/26]

void itpp::rshift_fix | ( | fixmat & | y,
|  | int | n,
|  | q_mode | q
| ) |  |

inline

Right shift `n` bits using the specified quantization mode `q`.

Definition at line 239 of file fix_functions.h.

References itpp::Mat< Num_T >::size().

## lshift_fix() [4/13]

void itpp::lshift_fix | ( | double & | ,
|  | int |
| ) |  |

inline

Dummy function useful in templated code.

Definition at line 242 of file fix_functions.h.

## rshift_fix() [7/26]

void itpp::rshift_fix | ( | double & | ,
|  | int |
| ) |  |

inline

Dummy function useful in templated code.

Definition at line 244 of file fix_functions.h.

## rshift_fix() [8/26]

void itpp::rshift_fix | ( | double & | ,
|  | int | ,
|  | q_mode |
| ) |  |

inline

Dummy function useful in templated code.

Definition at line 246 of file fix_functions.h.

## lshift_fix() [5/13]

void itpp::lshift_fix | ( | vec & | ,
|  | int |
| ) |  |

inline

Dummy function useful in templated code.

Definition at line 248 of file fix_functions.h.

## rshift_fix() [9/26]

void itpp::rshift_fix | ( | vec & | ,
|  | int |
| ) |  |

inline

Dummy function useful in templated code.

Definition at line 250 of file fix_functions.h.

## rshift_fix() [10/26]

void itpp::rshift_fix | ( | vec & | ,
|  | int | ,
|  | q_mode |
| ) |  |

inline

Dummy function useful in templated code.

Definition at line 252 of file fix_functions.h.

## lshift_fix() [6/13]

void itpp::lshift_fix | ( | mat & | ,
|  | int |
| ) |  |

inline

Dummy function useful in templated code.

Definition at line 254 of file fix_functions.h.

## rshift_fix() [11/26]

void itpp::rshift_fix | ( | mat & | ,
|  | int |
| ) |  |

inline

Dummy function useful in templated code.

Definition at line 256 of file fix_functions.h.

## rshift_fix() [12/26]

void itpp::rshift_fix | ( | mat & | ,
|  | int | ,
|  | q_mode |
| ) |  |

inline

Dummy function useful in templated code.

Definition at line 258 of file fix_functions.h.

## lshift_fix() [7/13]

void itpp::lshift_fix | ( | CFix & | y,
|  | int | n
| ) |  |

inline

Left shift `n` bits.

Definition at line 260 of file fix_functions.h.

References itpp::CFix::lshift().

## rshift_fix() [13/26]

void itpp::rshift_fix | ( | CFix & | y,
|  | int | n
| ) |  |

inline

Right shift `n` bits using the quantization mode of `y`.

Definition at line 262 of file fix_functions.h.

References itpp::CFix::rshift().

## rshift_fix() [14/26]

void itpp::rshift_fix | ( | CFix & | y,
|  | int | n,
|  | q_mode | q
| ) |  |

inline

Right shift `n` bits using the specified quantization mode `q`.

Definition at line 264 of file fix_functions.h.

References itpp::CFix::rshift().

## lshift_fix() [8/13]

void itpp::lshift_fix | ( | cfixvec & | y,
|  | int | n
| ) |  |

inline

Left shift `n` bits.

Definition at line 266 of file fix_functions.h.

References itpp::Vec< Num_T >::size().

## rshift_fix() [15/26]

void itpp::rshift_fix | ( | cfixvec & | y,
|  | int | n
| ) |  |

inline

Right shift `n` bits using the quantization mode of `y`.

Definition at line 269 of file fix_functions.h.

References itpp::Vec< Num_T >::size().

## rshift_fix() [16/26]

void itpp::rshift_fix | ( | cfixvec & | y,
|  | int | n,
|  | q_mode | q
| ) |  |

inline

Right shift `n` bits using the specified quantization mode `q`.

Definition at line 272 of file fix_functions.h.

References itpp::Vec< Num_T >::size().

## lshift_fix() [9/13]

void itpp::lshift_fix | ( | cfixmat & | y,
|  | int | n
| ) |  |

inline

Left shift `n` bits.

Definition at line 275 of file fix_functions.h.

References itpp::Mat< Num_T >::size().

## rshift_fix() [17/26]

void itpp::rshift_fix | ( | cfixmat & | y,
|  | int | n
| ) |  |

inline

Right shift `n` bits using the quantization mode of `y`.

Definition at line 278 of file fix_functions.h.

References itpp::Mat< Num_T >::size().

## rshift_fix() [18/26]

void itpp::rshift_fix | ( | cfixmat & | y,
|  | int | n,
|  | q_mode | q
| ) |  |

inline

Right shift `n` bits using the specified quantization mode `q`.

Definition at line 281 of file fix_functions.h.

References itpp::Mat< Num_T >::size().

## lshift_fix() [10/13]

void itpp::lshift_fix | ( | std::complex< double > & | ,
|  | int |
| ) |  |

inline

Dummy function useful in templated code.

Definition at line 284 of file fix_functions.h.

## rshift_fix() [19/26]

void itpp::rshift_fix | ( | std::complex< double > & | ,
|  | int |
| ) |  |

inline

Dummy function useful in templated code.

Definition at line 286 of file fix_functions.h.

## rshift_fix() [20/26]

void itpp::rshift_fix | ( | std::complex< double > & | ,
|  | int | ,
|  | q_mode |
| ) |  |

inline

Dummy function useful in templated code.

Definition at line 288 of file fix_functions.h.

## lshift_fix() [11/13]

void itpp::lshift_fix | ( | cvec & | ,
|  | int |
| ) |  |

inline

Dummy function useful in templated code.

Definition at line 290 of file fix_functions.h.

## rshift_fix() [21/26]

void itpp::rshift_fix | ( | cvec & | ,
|  | int |
| ) |  |

inline

Dummy function useful in templated code.

Definition at line 292 of file fix_functions.h.

## rshift_fix() [22/26]

void itpp::rshift_fix | ( | cvec & | ,
|  | int | ,
|  | q_mode |
| ) |  |

inline

Dummy function useful in templated code.

Definition at line 294 of file fix_functions.h.

## lshift_fix() [12/13]

void itpp::lshift_fix | ( | cmat & | ,
|  | int |
| ) |  |

inline

Dummy function useful in templated code.

Definition at line 296 of file fix_functions.h.

## rshift_fix() [23/26]

void itpp::rshift_fix | ( | cmat & | ,
|  | int |
| ) |  |

inline

Dummy function useful in templated code.

Definition at line 298 of file fix_functions.h.

## rshift_fix() [24/26]

void itpp::rshift_fix | ( | cmat & | ,
|  | int | ,
|  | q_mode |
| ) |  |

inline

Dummy function useful in templated code.

Definition at line 300 of file fix_functions.h.

## lshift_fix() [13/13]

template<class T >

void itpp::lshift_fix | ( | Array< T > & | y,
|  | int | n
| ) |  |

inline

Call lshift_fix for each Array element.

Definition at line 302 of file fix_functions.h.

References itpp::lshift_fix(), and itpp::Array< T >::size().

## rshift_fix() [25/26]

template<class T >

void itpp::rshift_fix | ( | Array< T > & | y,
|  | int | n
| ) |  |

inline

Call rshift_fix for each Array element.

Definition at line 305 of file fix_functions.h.

References itpp::rshift_fix(), and itpp::Array< T >::size().

## rshift_fix() [26/26]

template<class T >

void itpp::rshift_fix | ( | Array< T > & | y,
|  | int | n,
|  | q_mode | q
| ) |  |

inline

Call rshift_fix for each Array element.

Definition at line 308 of file fix_functions.h.

References itpp::rshift_fix(), and itpp::Array< T >::size().

## assert_fixshift() [1/4]

void itpp::assert_fixshift | ( | double | ,
|  | int |
| ) |  |

inline

If x is a fixed-point variable, assert that x has the specified shift value, otherwise do nothing.

Definition at line 312 of file fix_functions.h.

## assert_fixshift() [2/4]

void itpp::assert_fixshift | ( | const std::complex< double > & | ,
|  | int |
| ) |  |

inline

If x is a fixed-point variable, assert that x has the specified shift value, otherwise do nothing.

Definition at line 314 of file fix_functions.h.

## assert_fixshift() [3/4]

void itpp::assert_fixshift | ( | const Fix & | x,
|  | int | shift
| ) |  |

inline

If x is a fixed-point variable, assert that x has the specified shift value, otherwise do nothing.

Definition at line 316 of file fix_functions.h.

References itpp::Fix_Base::get_shift(), it_assert_debug, and itpp::to_str().

## assert_fixshift() [4/4]

void itpp::assert_fixshift | ( | const CFix & | x,
|  | int | shift
| ) |  |

inline

If x is a fixed-point variable, assert that x has the specified shift value, otherwise do nothing.

Definition at line 319 of file fix_functions.h.

References itpp::Fix_Base::get_shift(), it_assert_debug, and itpp::to_str().

## to_vec()

ITPP_EXPORT vec itpp::to_vec | ( | const fixvec & | v | ) |

Converts a fixvec to vec.

Definition at line 36 of file fix_functions.cpp.

References itpp::Array< T >::length().

## to_cvec()

ITPP_EXPORT cvec itpp::to_cvec | ( | const cfixvec & | v | ) |

Converts a cfixvec to cvec.

Definition at line 45 of file fix_functions.cpp.

References itpp::Array< T >::length().

## to_mat()

ITPP_EXPORT mat itpp::to_mat | ( | const fixmat & | m | ) |

Converts a fixmat to mat.

Definition at line 54 of file fix_functions.cpp.

References itpp::Mat< Num_T >::cols(), and itpp::Mat< Num_T >::rows().

## to_cmat()

ITPP_EXPORT cmat itpp::to_cmat | ( | const cfixmat & | m | ) |

Converts a cfixmat to cmat.

Definition at line 65 of file fix_functions.cpp.

References itpp::Mat< Num_T >::cols(), and itpp::Mat< Num_T >::rows().

## to() [1/12]

template<class T >

T itpp::to | ( | double | x | ) |

inline

Convert double to T.

Definition at line 365 of file fix_functions.h.

Referenced by itpp::Mat< Num_T >::copy_col(), itpp::Mat< Num_T >::copy_row(), itpp::Histogram< Num_T >::Histogram(), itpp::linspace(), itpp::linspace_fixed_step(), and itpp::Histogram< Num_T >::setup().

## to() [2/12]

template<class T >

T itpp::to | ( | const Fix & | x | ) |

inline

Convert Fix to T.

Definition at line 367 of file fix_functions.h.

## to() [3/12]

template<class T >

T itpp::to | ( | const std::complex< double > & | x | ) |

inline

Convert std::complex<double> to T.

Definition at line 369 of file fix_functions.h.

## to() [4/12]

template<class T >

T itpp::to | ( | const CFix & | x | ) |

inline

Convert CFix to T.

Definition at line 371 of file fix_functions.h.

## to() [5/12]

template<class T >

T itpp::to | ( | double | real,
|  | double | imag
| ) |  |

inline

Convert double (real and imaginary parts) to T.

Definition at line 373 of file fix_functions.h.

References itpp::imag(), and itpp::real().

## to() [6/12]

template<class T >

T itpp::to | ( | const Fix & | real,
|  | const Fix & | imag
| ) |  |

inline

Convert Fix (real and imaginary parts) to T.

Definition at line 375 of file fix_functions.h.

References itpp::imag(), and itpp::real().

## to() [7/12]

template<class T , class U >

Vec< T > itpp::to | ( | const Vec< U > & | x | ) |

Convert Vec to Vec<T>

Definition at line 378 of file fix_functions.h.

References itpp::Array< T >::length().

## to< double >() [1/2]

template<>

vec itpp::to< double > | ( | const vec & | x | ) |

inline

Convert vec to vec.

Definition at line 387 of file fix_functions.h.

## to< std::complex< double > >() [1/2]

template<>

cvec itpp::to< std::complex< double > > | ( | const cvec & | x | ) |

inline

Convert cvec to cvec.

Definition at line 389 of file fix_functions.h.

## to< Fix >() [1/2]

template<>

fixvec itpp::to< Fix > | ( | const fixvec & | x | ) |

inline

Convert fixvec to fixvec.

Definition at line 391 of file fix_functions.h.

## to< CFix >() [1/2]

template<>

cfixvec itpp::to< CFix > | ( | const cfixvec & | x | ) |

inline

Convert cfixvec to cfixvec.

Definition at line 393 of file fix_functions.h.

Referenced by itpp::operator*(), itpp::operator*(), itpp::operator*(), itpp::operator*(), itpp::operator*(), itpp::operator*(), itpp::operator*(), itpp::operator*(), itpp::operator+(), itpp::operator+(), itpp::operator+(), itpp::operator+(), itpp::operator+(), itpp::operator+(), itpp::operator+(), itpp::operator+(), itpp::operator-(), itpp::operator-(), itpp::operator-(), itpp::operator-(), itpp::operator-(), itpp::operator-(), itpp::operator-(), itpp::operator-(), itpp::operator/(), itpp::operator/(), itpp::operator/(), and itpp::operator/().

## to() [8/12]

template<class T , class U >

Vec< T > itpp::to | ( | const Vec< U > & | real,
|  | const Vec< U > & | imag
| ) |  |

Convert Vec (real and imaginary parts) to Vec<T>

Definition at line 396 of file fix_functions.h.

References itpp::imag(), it_assert_debug, itpp::Array< T >::length(), and itpp::real().

## to() [9/12]

template<class T , class U >

Mat< T > itpp::to | ( | const Mat< U > & | x | ) |

Convert Mat to Mat<T>

Definition at line 407 of file fix_functions.h.

## to< double >() [2/2]

template<>

mat itpp::to< double > | ( | const mat & | x | ) |

inline

Convert mat to mat.

Definition at line 418 of file fix_functions.h.

## to< std::complex< double > >() [2/2]

template<>

cmat itpp::to< std::complex< double > > | ( | const cmat & | x | ) |

inline

Convert cmat to cmat.

Definition at line 420 of file fix_functions.h.

## to< Fix >() [2/2]

template<>

fixmat itpp::to< Fix > | ( | const fixmat & | x | ) |

inline

Convert fixmat to fixmat.

Definition at line 422 of file fix_functions.h.

## to< CFix >() [2/2]

template<>

cfixmat itpp::to< CFix > | ( | const cfixmat & | x | ) |

inline

Convert cfixmat to cfixmat.

Definition at line 424 of file fix_functions.h.

## to() [10/12]

template<class T , class U >

Mat< T > itpp::to | ( | const Mat< U > & | real,
|  | const Mat< U > & | imag
| ) |  |

Convert Mat (real and imaginary parts) to Mat<T>

Definition at line 427 of file fix_functions.h.

References itpp::imag(), it_assert_debug, and itpp::real().

## to() [11/12]

template<class T , class U >

Array< typename ConvertU2T< T, U >::result > itpp::to | ( | const Array< U > & | x | ) |

Convert Array, where U can be an Array/Vec/Mat, to a corresponding Array with T elements.

Definition at line 441 of file fix_functions.h.

References itpp::Array< T >::size().

## to() [12/12]

template<class T , class U >

Array< typename ConvertU2T< T, U >::result > itpp::to | ( | const Array< U > & | real,
|  | const Array< U > & | imag
| ) |  |

Convert Array (real and imaginary parts), where U can be an Array/Vec/Mat, to a corresponding Array with T elements.

Definition at line 452 of file fix_functions.h.

References itpp::imag(), it_assert_debug, itpp::real(), and itpp::Array< T >::size().

## unfix() [1/13]

double itpp::unfix | ( | const Fix & | x | ) |

inline

Convert Fix to double by multiplying the bit representation with pow2(-shift)

Definition at line 463 of file fix_functions.h.

References itpp::Fix::unfix().

Referenced by itpp::unfix().

## unfix() [2/13]

std::complex< double > itpp::unfix | ( | const CFix & | x | ) |

inline

Convert CFix to std::complex<double> by multiplying the bit representation with pow2(-shift)

Definition at line 465 of file fix_functions.h.

References itpp::CFix::unfix().

## unfix() [3/13]

vec itpp::unfix | ( | const fixvec & | x | ) |

inline

Convert fixvec to vec by multiplying the bit representations with pow2(-shift)

Definition at line 467 of file fix_functions.h.

References itpp::to_vec().

## unfix() [4/13]

cvec itpp::unfix | ( | const cfixvec & | x | ) |

inline

Convert cfixvec to cvec by multiplying the bit representations with pow2(-shift)

Definition at line 469 of file fix_functions.h.

References itpp::to_cvec().

## unfix() [5/13]

mat itpp::unfix | ( | const fixmat & | x | ) |

inline

Convert fixmat to mat by multiplying the bit representations with pow2(-shift)

Definition at line 471 of file fix_functions.h.

References itpp::to_mat().

## unfix() [6/13]

cmat itpp::unfix | ( | const cfixmat & | x | ) |

inline

Convert cfixmat to cmat by multiplying the bit representations with pow2(-shift)

Definition at line 473 of file fix_functions.h.

References itpp::to_cmat().

## unfix() [7/13]

double itpp::unfix | ( | double | x | ) |

inline

Convert double to double i.e. do nothing.

Definition at line 476 of file fix_functions.h.

## unfix() [8/13]

std::complex< double > itpp::unfix | ( | const std::complex< double > & | x | ) |

inline

Convert std::complex<double> to std::complex<double> i.e. do nothing.

Definition at line 478 of file fix_functions.h.

## unfix() [9/13]

vec itpp::unfix | ( | const vec & | x | ) |

inline

Convert vec to vec i.e. do nothing.

Definition at line 480 of file fix_functions.h.

## unfix() [10/13]

cvec itpp::unfix | ( | const cvec & | x | ) |

inline

Convert cvec to cvec i.e. do nothing.

Definition at line 482 of file fix_functions.h.

## unfix() [11/13]

mat itpp::unfix | ( | const mat & | x | ) |

inline

Convert mat to mat i.e. do nothing.

Definition at line 484 of file fix_functions.h.

## unfix() [12/13]

cmat itpp::unfix | ( | const cmat & | x | ) |

inline

Convert cmat to cmat i.e. do nothing.

Definition at line 486 of file fix_functions.h.

## unfix() [13/13]

template<class T >

Array< typename Convert< T >::to_double > itpp::unfix | ( | const Array< T > & | x | ) |

Convert floating- or fixed-point Array to floating-point Array.

Definition at line 537 of file fix_functions.h.

References itpp::Array< T >::size(), and itpp::unfix().

## abs()

ITPP_EXPORT Fix itpp::abs | ( | const Fix & | x | ) |

Absolute value.

Definition at line 76 of file fix_functions.cpp.

References itpp::Fix::get_re(), and itpp::Fix_Base::get_shift().

## real()

ITPP_EXPORT Fix itpp::real | ( | const CFix & | x | ) |

Real part of complex value.

Definition at line 84 of file fix_functions.cpp.

References itpp::CFix::get_re(), and itpp::Fix_Base::get_shift().

## imag()

ITPP_EXPORT Fix itpp::imag | ( | const CFix & | x | ) |

Imaginary part of complex value.

Definition at line 91 of file fix_functions.cpp.

References itpp::CFix::get_im(), and itpp::Fix_Base::get_shift().

## conj()

ITPP_EXPORT CFix itpp::conj | ( | const CFix & | x | ) |

Conjugate of complex value.

Definition at line 98 of file fix_functions.cpp.

References itpp::CFix::get_im(), itpp::CFix::get_re(), and itpp::Fix_Base::get_shift().

## operator+() [1/40]

ITPP_EXPORT Fix itpp::operator+ | ( | const Fix & | x,
|  | const Fix & | y
| ) |  |

Fix + Fix.

Definition at line 40 of file fix_operators.cpp.

References itpp::assert_shifts(), and itpp::Fix::get_re().

## operator-() [1/40]

ITPP_EXPORT Fix itpp::operator- | ( | const Fix & | x,
|  | const Fix & | y
| ) |  |

Fix - Fix.

Definition at line 47 of file fix_operators.cpp.

References itpp::assert_shifts(), and itpp::Fix::get_re().

## operator*() [1/40]

ITPP_EXPORT Fix itpp::operator* | ( | const Fix & | x,
|  | const Fix & | y
| ) |  |

Fix * Fix.

Definition at line 54 of file fix_operators.cpp.

References itpp::Fix::get_re(), and itpp::Fix_Base::get_shift().

## operator/() [1/18]

ITPP_EXPORT Fix itpp::operator/ | ( | const Fix & | x,
|  | const Fix & | y
| ) |  |

Fix / Fix using quantization mode `TRN`.

Definition at line 61 of file fix_operators.cpp.

References itpp::Fix::get_re(), and itpp::Fix_Base::get_shift().

## operator+() [2/40]

ITPP_EXPORT Fix itpp::operator+ | ( | const Fix & | x,
|  | const int | y
| ) |  |

Fix + int.

Definition at line 68 of file fix_operators.cpp.

References itpp::assert_shifts(), and itpp::Fix::get_re().

## operator-() [2/40]

ITPP_EXPORT Fix itpp::operator- | ( | const Fix & | x,
|  | const int | y
| ) |  |

Fix - int.

Definition at line 75 of file fix_operators.cpp.

References itpp::assert_shifts(), and itpp::Fix::get_re().

## operator*() [2/40]

ITPP_EXPORT Fix itpp::operator* | ( | const Fix & | x,
|  | const int | y
| ) |  |

Fix * int.

Definition at line 82 of file fix_operators.cpp.

References itpp::Fix::get_re(), and itpp::Fix_Base::get_shift().

## operator/() [2/18]

ITPP_EXPORT Fix itpp::operator/ | ( | const Fix & | x,
|  | const int | y
| ) |  |

Fix / int using quantization mode `TRN`.

Definition at line 89 of file fix_operators.cpp.

References itpp::Fix::get_re(), and itpp::Fix_Base::get_shift().

## operator+() [3/40]

ITPP_EXPORT Fix itpp::operator+ | ( | const int | x,
|  | const Fix & | y
| ) |  |

int + Fix

Definition at line 96 of file fix_operators.cpp.

References itpp::assert_shifts(), and itpp::Fix::get_re().

## operator-() [3/40]

ITPP_EXPORT Fix itpp::operator- | ( | const int | x,
|  | const Fix & | y
| ) |  |

int - Fix

Definition at line 103 of file fix_operators.cpp.

References itpp::assert_shifts(), and itpp::Fix::get_re().

## operator*() [3/40]

ITPP_EXPORT Fix itpp::operator* | ( | const int | x,
|  | const Fix & | y
| ) |  |

int * Fix

Definition at line 110 of file fix_operators.cpp.

References itpp::Fix::get_re(), and itpp::Fix_Base::get_shift().

## operator/() [3/18]

ITPP_EXPORT Fix itpp::operator/ | ( | const int | x,
|  | const Fix & | y
| ) |  |

int / Fix using quantization mode `TRN`

Definition at line 117 of file fix_operators.cpp.

References itpp::Fix::get_re(), and itpp::Fix_Base::get_shift().

## operator+() [4/40]

fixvec itpp::operator+ | ( | const fixvec & | v,
|  | const int | s
| ) |  |

inline

fixvec + int

Definition at line 75 of file fix_operators.h.

## operator+() [5/40]

fixvec itpp::operator+ | ( | const int | s,
|  | const fixvec & | v
| ) |  |

inline

int + fixvec

Definition at line 77 of file fix_operators.h.

## operator-() [4/40]

fixvec itpp::operator- | ( | const fixvec & | v,
|  | const int | s
| ) |  |

inline

fixvec - int

Definition at line 79 of file fix_operators.h.

## operator-() [5/40]

fixvec itpp::operator- | ( | const int | s,
|  | const fixvec & | v
| ) |  |

inline

int - fixvec

Definition at line 81 of file fix_operators.h.

## operator*() [4/40]

fixvec itpp::operator* | ( | const fixvec & | v,
|  | const int | s
| ) |  |

inline

fixvec * int

Definition at line 83 of file fix_operators.h.

## operator*() [5/40]

fixvec itpp::operator* | ( | const int | s,
|  | const fixvec & | v
| ) |  |

inline

int * fixvec

Definition at line 85 of file fix_operators.h.

## operator/() [4/18]

fixvec itpp::operator/ | ( | const fixvec & | v,
|  | const int | s
| ) |  |

inline

fixvec / int using quantization mode `TRN`

Definition at line 87 of file fix_operators.h.

## operator+() [6/40]

fixmat itpp::operator+ | ( | const fixmat & | v,
|  | const int | s
| ) |  |

inline

fixmat + int

Definition at line 90 of file fix_operators.h.

## operator+() [7/40]

fixmat itpp::operator+ | ( | const int | s,
|  | const fixmat & | v
| ) |  |

inline

int + fixmat

Definition at line 92 of file fix_operators.h.

## operator-() [6/40]

fixmat itpp::operator- | ( | const fixmat & | v,
|  | const int | s
| ) |  |

inline

fixmat - int

Definition at line 94 of file fix_operators.h.

## operator-() [7/40]

fixmat itpp::operator- | ( | const int | s,
|  | const fixmat & | v
| ) |  |

inline

int - fixmat

Definition at line 96 of file fix_operators.h.

## operator*() [6/40]

fixmat itpp::operator* | ( | const fixmat & | v,
|  | const int | s
| ) |  |

inline

fixmat * int

Definition at line 98 of file fix_operators.h.

## operator*() [7/40]

fixmat itpp::operator* | ( | const int | s,
|  | const fixmat & | v
| ) |  |

inline

int * fixmat

Definition at line 100 of file fix_operators.h.

## operator/() [5/18]

fixmat itpp::operator/ | ( | const fixmat & | v,
|  | const int | s
| ) |  |

inline

fixmat / int using quantization mode `TRN`

Definition at line 102 of file fix_operators.h.

## operator+() [8/40]

ITPP_EXPORT fixvec itpp::operator+ | ( | const fixvec & | a,
|  | const ivec & | b
| ) |  |

fixvec + ivec

Definition at line 125 of file fix_operators.cpp.

References it_assert_debug, and itpp::Array< T >::size().

## operator+() [9/40]

fixvec itpp::operator+ | ( | const ivec & | a,
|  | const fixvec & | b
| ) |  |

inline

ivec + fixvec

Definition at line 107 of file fix_operators.h.

## operator-() [8/40]

fixvec itpp::operator- | ( | const fixvec & | a,
|  | const ivec & | b
| ) |  |

inline

fixvec - ivec

Definition at line 109 of file fix_operators.h.

## operator-() [9/40]

fixvec itpp::operator- | ( | const ivec & | a,
|  | const fixvec & | b
| ) |  |

inline

ivec - fixvec

Definition at line 111 of file fix_operators.h.

## operator*() [8/40]

ITPP_EXPORT Fix itpp::operator* | ( | const fixvec & | a,
|  | const ivec & | b
| ) |  |

fixvec * ivec

Definition at line 135 of file fix_operators.cpp.

References it_assert_debug, and itpp::Array< T >::size().

## operator*() [9/40]

Fix itpp::operator* | ( | const ivec & | a,
|  | const fixvec & | b
| ) |  |

inline

ivec * fixvec

Definition at line 115 of file fix_operators.h.

## operator+() [10/40]

ITPP_EXPORT fixmat itpp::operator+ | ( | const fixmat & | a,
|  | const imat & | b
| ) |  |

fixmat + imat

Definition at line 145 of file fix_operators.cpp.

References it_assert_debug.

## operator+() [11/40]

fixmat itpp::operator+ | ( | const imat & | a,
|  | const fixmat & | b
| ) |  |

inline

imat + fixmat

Definition at line 120 of file fix_operators.h.

## operator-() [10/40]

fixmat itpp::operator- | ( | const fixmat & | a,
|  | const imat & | b
| ) |  |

inline

fixmat - imat

Definition at line 122 of file fix_operators.h.

## operator-() [11/40]

fixmat itpp::operator- | ( | const imat & | a,
|  | const fixmat & | b
| ) |  |

inline

imat - fixmat

Definition at line 124 of file fix_operators.h.

## operator*() [10/40]

ITPP_EXPORT fixmat itpp::operator* | ( | const fixmat & | a,
|  | const imat & | b
| ) |  |

fixmat * imat

Definition at line 158 of file fix_operators.cpp.

References itpp::Mat< Num_T >::_data(), itpp::Mat< Num_T >::cols(), it_assert_debug, and itpp::Mat< Num_T >::rows().

## operator*() [11/40]

fixmat itpp::operator* | ( | const imat & | a,
|  | const fixmat & | b
| ) |  |

inline

imat * fixmat

Definition at line 128 of file fix_operators.h.

## operator+() [12/40]

ITPP_EXPORT CFix itpp::operator+ | ( | const CFix & | x,
|  | const CFix & | y
| ) |  |

CFix + CFix.

Definition at line 189 of file fix_operators.cpp.

References itpp::assert_shifts(), itpp::CFix::get_im(), and itpp::CFix::get_re().

## operator-() [12/40]

ITPP_EXPORT CFix itpp::operator- | ( | const CFix & | x,
|  | const CFix & | y
| ) |  |

CFix - CFix.

Definition at line 197 of file fix_operators.cpp.

References itpp::assert_shifts(), itpp::CFix::get_im(), and itpp::CFix::get_re().

## operator*() [12/40]

ITPP_EXPORT CFix itpp::operator* | ( | const CFix & | x,
|  | const CFix & | y
| ) |  |

CFix * CFix.

Definition at line 205 of file fix_operators.cpp.

References itpp::CFix::get_im(), itpp::CFix::get_re(), and itpp::Fix_Base::get_shift().

## operator/() [6/18]

ITPP_EXPORT CFix itpp::operator/ | ( | const CFix & | x,
|  | const CFix & | y
| ) |  |

CFix / CFix using quantization mode `TRN`.

Definition at line 213 of file fix_operators.cpp.

References itpp::CFix::get_im(), itpp::CFix::get_re(), and itpp::Fix_Base::get_shift().

## operator+() [13/40]

ITPP_EXPORT CFix itpp::operator+ | ( | const CFix & | x,
|  | const Fix & | y
| ) |  |

CFix + Fix.

Definition at line 222 of file fix_operators.cpp.

References itpp::assert_shifts(), itpp::CFix::get_im(), itpp::CFix::get_re(), and itpp::Fix::get_re().

## operator-() [13/40]

ITPP_EXPORT CFix itpp::operator- | ( | const CFix & | x,
|  | const Fix & | y
| ) |  |

CFix - Fix.

Definition at line 230 of file fix_operators.cpp.

References itpp::assert_shifts(), itpp::CFix::get_im(), itpp::CFix::get_re(), and itpp::Fix::get_re().

## operator*() [13/40]

ITPP_EXPORT CFix itpp::operator* | ( | const CFix & | x,
|  | const Fix & | y
| ) |  |

CFix * Fix.

Definition at line 238 of file fix_operators.cpp.

References itpp::CFix::get_im(), itpp::CFix::get_re(), itpp::Fix::get_re(), and itpp::Fix_Base::get_shift().

## operator/() [7/18]

ITPP_EXPORT CFix itpp::operator/ | ( | const CFix & | x,
|  | const Fix & | y
| ) |  |

CFix / Fix using quantization mode `TRN`.

Definition at line 246 of file fix_operators.cpp.

References itpp::CFix::get_im(), itpp::CFix::get_re(), itpp::Fix::get_re(), and itpp::Fix_Base::get_shift().

## operator+() [14/40]

ITPP_EXPORT CFix itpp::operator+ | ( | const Fix & | x,
|  | const CFix & | y
| ) |  |

Fix + CFix.

Definition at line 254 of file fix_operators.cpp.

References itpp::assert_shifts(), itpp::CFix::get_im(), itpp::CFix::get_re(), and itpp::Fix::get_re().

## operator-() [14/40]

ITPP_EXPORT CFix itpp::operator- | ( | const Fix & | x,
|  | const CFix & | y
| ) |  |

Fix - CFix.

Definition at line 262 of file fix_operators.cpp.

References itpp::assert_shifts(), itpp::CFix::get_im(), itpp::CFix::get_re(), and itpp::Fix::get_re().

## operator*() [14/40]

ITPP_EXPORT CFix itpp::operator* | ( | const Fix & | x,
|  | const CFix & | y
| ) |  |

Fix * CFix.

Definition at line 270 of file fix_operators.cpp.

References itpp::CFix::get_im(), itpp::CFix::get_re(), itpp::Fix::get_re(), and itpp::Fix_Base::get_shift().

## operator/() [8/18]

ITPP_EXPORT CFix itpp::operator/ | ( | const Fix & | x,
|  | const CFix & | y
| ) |  |

Fix / CFix using quantization mode `TRN`.

Definition at line 278 of file fix_operators.cpp.

References itpp::CFix::get_im(), itpp::CFix::get_re(), itpp::Fix::get_re(), and itpp::Fix_Base::get_shift().

## operator+() [15/40]

ITPP_EXPORT CFix itpp::operator+ | ( | const CFix & | x,
|  | const int | y
| ) |  |

CFix + int.

Definition at line 287 of file fix_operators.cpp.

References itpp::assert_shifts(), itpp::CFix::get_im(), and itpp::CFix::get_re().

## operator-() [15/40]

ITPP_EXPORT CFix itpp::operator- | ( | const CFix & | x,
|  | const int | y
| ) |  |

CFix - int.

Definition at line 295 of file fix_operators.cpp.

References itpp::assert_shifts(), itpp::CFix::get_im(), and itpp::CFix::get_re().

## operator*() [15/40]

ITPP_EXPORT CFix itpp::operator* | ( | const CFix & | x,
|  | const int | y
| ) |  |

CFix * int.

Definition at line 303 of file fix_operators.cpp.

References itpp::CFix::get_im(), itpp::CFix::get_re(), and itpp::Fix_Base::get_shift().

## operator/() [9/18]

ITPP_EXPORT CFix itpp::operator/ | ( | const CFix & | x,
|  | const int | y
| ) |  |

CFix / int using quantization mode `TRN`.

Definition at line 311 of file fix_operators.cpp.

References itpp::CFix::get_im(), itpp::CFix::get_re(), and itpp::Fix_Base::get_shift().

## operator+() [16/40]

ITPP_EXPORT CFix itpp::operator+ | ( | const int | x,
|  | const CFix & | y
| ) |  |

int + CFix

Definition at line 319 of file fix_operators.cpp.

References itpp::assert_shifts(), itpp::CFix::get_im(), and itpp::CFix::get_re().

## operator-() [16/40]

ITPP_EXPORT CFix itpp::operator- | ( | const int | x,
|  | const CFix & | y
| ) |  |

int - CFix

Definition at line 327 of file fix_operators.cpp.

References itpp::assert_shifts(), itpp::CFix::get_im(), and itpp::CFix::get_re().

## operator*() [16/40]

ITPP_EXPORT CFix itpp::operator* | ( | const int | x,
|  | const CFix & | y
| ) |  |

int * CFix

Definition at line 335 of file fix_operators.cpp.

References itpp::CFix::get_im(), itpp::CFix::get_re(), and itpp::Fix_Base::get_shift().

## operator/() [10/18]

ITPP_EXPORT CFix itpp::operator/ | ( | const int | x,
|  | const CFix & | y
| ) |  |

int / CFix using quantization mode `TRN`

Definition at line 343 of file fix_operators.cpp.

References itpp::CFix::get_im(), itpp::CFix::get_re(), and itpp::Fix_Base::get_shift().

## operator+() [17/40]

cfixvec itpp::operator+ | ( | const fixvec & | v,
|  | const CFix & | s
| ) |  |

inline

fixvec + CFix

Definition at line 178 of file fix_operators.h.

References itpp::to< CFix >().

## operator+() [18/40]

cfixvec itpp::operator+ | ( | const CFix & | s,
|  | const fixvec & | v
| ) |  |

inline

CFix + fixvec.

Definition at line 180 of file fix_operators.h.

References itpp::to< CFix >().

## operator-() [17/40]

cfixvec itpp::operator- | ( | const fixvec & | v,
|  | const CFix & | s
| ) |  |

inline

fixvec - CFix

Definition at line 182 of file fix_operators.h.

References itpp::to< CFix >().

## operator-() [18/40]

cfixvec itpp::operator- | ( | const CFix & | s,
|  | const fixvec & | v
| ) |  |

inline

CFix - fixvec.

Definition at line 184 of file fix_operators.h.

References itpp::to< CFix >().

## operator*() [17/40]

cfixvec itpp::operator* | ( | const fixvec & | v,
|  | const CFix & | s
| ) |  |

inline

fixvec * CFix

Definition at line 186 of file fix_operators.h.

References itpp::to< CFix >().

## operator*() [18/40]

cfixvec itpp::operator* | ( | const CFix & | s,
|  | const fixvec & | v
| ) |  |

inline

CFix * fixvec.

Definition at line 188 of file fix_operators.h.

References itpp::to< CFix >().

## operator/() [11/18]

cfixvec itpp::operator/ | ( | const fixvec & | v,
|  | const CFix & | s
| ) |  |

inline

fixvec / CFix using quantization mode `TRN`

Definition at line 190 of file fix_operators.h.

References itpp::to< CFix >().

## operator+() [19/40]

cfixmat itpp::operator+ | ( | const fixmat & | m,
|  | const CFix & | s
| ) |  |

inline

fixmat + CFix

Definition at line 193 of file fix_operators.h.

References itpp::to< CFix >().

## operator+() [20/40]

cfixmat itpp::operator+ | ( | const CFix & | s,
|  | const fixmat & | m
| ) |  |

inline

CFix + fixmat.

Definition at line 195 of file fix_operators.h.

References itpp::to< CFix >().

## operator-() [19/40]

cfixmat itpp::operator- | ( | const fixmat & | m,
|  | const CFix & | s
| ) |  |

inline

fixmat - CFix

Definition at line 197 of file fix_operators.h.

References itpp::to< CFix >().

## operator-() [20/40]

cfixmat itpp::operator- | ( | const CFix & | s,
|  | const fixmat & | m
| ) |  |

inline

CFix - fixmat.

Definition at line 199 of file fix_operators.h.

References itpp::to< CFix >().

## operator*() [19/40]

cfixmat itpp::operator* | ( | const fixmat & | m,
|  | const CFix & | s
| ) |  |

inline

fixmat * CFix

Definition at line 201 of file fix_operators.h.

References itpp::to< CFix >().

## operator*() [20/40]

cfixmat itpp::operator* | ( | const CFix & | s,
|  | const fixmat & | m
| ) |  |

inline

CFix * fixmat.

Definition at line 203 of file fix_operators.h.

References itpp::to< CFix >().

## operator/() [12/18]

cfixmat itpp::operator/ | ( | const fixmat & | m,
|  | const CFix & | s
| ) |  |

inline

fixmat / CFix using quantization mode `TRN`

Definition at line 205 of file fix_operators.h.

References itpp::to< CFix >().

## operator+() [21/40]

cfixvec itpp::operator+ | ( | const ivec & | v,
|  | const CFix & | s
| ) |  |

inline

ivec + CFix

Definition at line 208 of file fix_operators.h.

References itpp::to< CFix >(), and itpp::to_vec().

## operator+() [22/40]

cfixvec itpp::operator+ | ( | const CFix & | s,
|  | const ivec & | v
| ) |  |

inline

CFix + ivec.

Definition at line 210 of file fix_operators.h.

References itpp::to< CFix >(), and itpp::to_vec().

## operator-() [21/40]

cfixvec itpp::operator- | ( | const ivec & | v,
|  | const CFix & | s
| ) |  |

inline

ivec - CFix

Definition at line 212 of file fix_operators.h.

References itpp::to< CFix >(), and itpp::to_vec().

## operator-() [22/40]

cfixvec itpp::operator- | ( | const CFix & | s,
|  | const ivec & | v
| ) |  |

inline

CFix - ivec.

Definition at line 214 of file fix_operators.h.

References itpp::to< CFix >(), and itpp::to_vec().

## operator*() [21/40]

cfixvec itpp::operator* | ( | const ivec & | v,
|  | const CFix & | s
| ) |  |

inline

ivec * CFix

Definition at line 216 of file fix_operators.h.

References itpp::to< CFix >(), and itpp::to_vec().

## operator*() [22/40]

cfixvec itpp::operator* | ( | const CFix & | s,
|  | const ivec & | v
| ) |  |

inline

CFix * ivec.

Definition at line 218 of file fix_operators.h.

References itpp::to< CFix >(), and itpp::to_vec().

## operator/() [13/18]

cfixvec itpp::operator/ | ( | const ivec & | v,
|  | const CFix & | s
| ) |  |

inline

ivec / CFix using quantization mode `TRN`

Definition at line 220 of file fix_operators.h.

References itpp::to< CFix >(), and itpp::to_vec().

## operator+() [23/40]

cfixmat itpp::operator+ | ( | const imat & | m,
|  | const CFix & | s
| ) |  |

inline

imat + CFix

Definition at line 223 of file fix_operators.h.

References itpp::to< CFix >(), and itpp::to_mat().

## operator+() [24/40]

cfixmat itpp::operator+ | ( | const CFix & | s,
|  | const imat & | m
| ) |  |

inline

CFix + imat.

Definition at line 225 of file fix_operators.h.

References itpp::to< CFix >(), and itpp::to_mat().

## operator-() [23/40]

cfixmat itpp::operator- | ( | const imat & | m,
|  | const CFix & | s
| ) |  |

inline

imat - CFix

Definition at line 227 of file fix_operators.h.

References itpp::to< CFix >(), and itpp::to_mat().

## operator-() [24/40]

cfixmat itpp::operator- | ( | const CFix & | s,
|  | const imat & | m
| ) |  |

inline

CFix - imat.

Definition at line 229 of file fix_operators.h.

References itpp::to< CFix >(), and itpp::to_mat().

## operator*() [23/40]

cfixmat itpp::operator* | ( | const imat & | m,
|  | const CFix & | s
| ) |  |

inline

imat * CFix

Definition at line 231 of file fix_operators.h.

References itpp::to< CFix >(), and itpp::to_mat().

## operator*() [24/40]

cfixmat itpp::operator* | ( | const CFix & | s,
|  | const imat & | m
| ) |  |

inline

CFix * imat.

Definition at line 233 of file fix_operators.h.

References itpp::to< CFix >(), and itpp::to_mat().

## operator/() [14/18]

cfixmat itpp::operator/ | ( | const imat & | m,
|  | const CFix & | s
| ) |  |

inline

imat / CFix using quantization mode `TRN`

Definition at line 235 of file fix_operators.h.

References itpp::to< CFix >(), and itpp::to_mat().

## operator+() [25/40]

cfixvec itpp::operator+ | ( | const cfixvec & | v,
|  | const Fix & | s
| ) |  |

inline

cfixvec + Fix

Definition at line 238 of file fix_operators.h.

## operator+() [26/40]

cfixvec itpp::operator+ | ( | const Fix & | s,
|  | const cfixvec & | v
| ) |  |

inline

Fix + cfixvec.

Definition at line 240 of file fix_operators.h.

## operator-() [25/40]

cfixvec itpp::operator- | ( | const cfixvec & | v,
|  | const Fix & | s
| ) |  |

inline

cfixvec - Fix

Definition at line 242 of file fix_operators.h.

## operator-() [26/40]

cfixvec itpp::operator- | ( | const Fix & | s,
|  | const cfixvec & | v
| ) |  |

inline

Fix - cfixvec.

Definition at line 244 of file fix_operators.h.

## operator*() [25/40]

cfixvec itpp::operator* | ( | const cfixvec & | v,
|  | const Fix & | s
| ) |  |

inline

cfixvec * Fix

Definition at line 246 of file fix_operators.h.

## operator*() [26/40]

cfixvec itpp::operator* | ( | const Fix & | s,
|  | const cfixvec & | v
| ) |  |

inline

Fix * cfixvec.

Definition at line 248 of file fix_operators.h.

## operator/() [15/18]

cfixvec itpp::operator/ | ( | const cfixvec & | v,
|  | const Fix & | s
| ) |  |

inline

cfixvec / Fix using quantization mode `TRN`

Definition at line 250 of file fix_operators.h.

## operator+() [27/40]

cfixmat itpp::operator+ | ( | const cfixmat & | m,
|  | const Fix & | s
| ) |  |

inline

cfixmat + Fix

Definition at line 253 of file fix_operators.h.

## operator+() [28/40]

cfixmat itpp::operator+ | ( | const Fix & | s,
|  | const cfixmat & | m
| ) |  |

inline

Fix + cfixmat.

Definition at line 255 of file fix_operators.h.

## operator-() [27/40]

cfixmat itpp::operator- | ( | const cfixmat & | m,
|  | const Fix & | s
| ) |  |

inline

cfixmat - Fix

Definition at line 257 of file fix_operators.h.

## operator-() [28/40]

cfixmat itpp::operator- | ( | const Fix & | s,
|  | const cfixmat & | m
| ) |  |

inline

Fix - cfixmat.

Definition at line 259 of file fix_operators.h.

## operator*() [27/40]

cfixmat itpp::operator* | ( | const cfixmat & | m,
|  | const Fix & | s
| ) |  |

inline

cfixmat * Fix

Definition at line 261 of file fix_operators.h.

## operator*() [28/40]

cfixmat itpp::operator* | ( | const Fix & | s,
|  | const cfixmat & | m
| ) |  |

inline

Fix * cfixmat.

Definition at line 263 of file fix_operators.h.

## operator/() [16/18]

cfixmat itpp::operator/ | ( | const cfixmat & | m,
|  | const Fix & | s
| ) |  |

inline

cfixmat / Fix using quantization mode `TRN`

Definition at line 265 of file fix_operators.h.

## operator+() [29/40]

cfixvec itpp::operator+ | ( | const cfixvec & | v,
|  | const int | s
| ) |  |

inline

cfixvec + int

Definition at line 268 of file fix_operators.h.

## operator+() [30/40]

cfixvec itpp::operator+ | ( | const int | s,
|  | const cfixvec & | v
| ) |  |

inline

int + cfixvec

Definition at line 270 of file fix_operators.h.

## operator-() [29/40]

cfixvec itpp::operator- | ( | const cfixvec & | v,
|  | const int | s
| ) |  |

inline

cfixvec - int

Definition at line 272 of file fix_operators.h.

## operator-() [30/40]

cfixvec itpp::operator- | ( | const int | s,
|  | const cfixvec & | v
| ) |  |

inline

int - cfixvec

Definition at line 274 of file fix_operators.h.

## operator*() [29/40]

cfixvec itpp::operator* | ( | const cfixvec & | v,
|  | const int | s
| ) |  |

inline

cfixvec * int

Definition at line 276 of file fix_operators.h.

## operator*() [30/40]

cfixvec itpp::operator* | ( | const int | s,
|  | const cfixvec & | v
| ) |  |

inline

int * cfixvec

Definition at line 278 of file fix_operators.h.

## operator/() [17/18]

cfixvec itpp::operator/ | ( | const cfixvec & | v,
|  | const int | s
| ) |  |

inline

cfixvec / int using quantization mode `TRN`

Definition at line 280 of file fix_operators.h.

## operator+() [31/40]

cfixmat itpp::operator+ | ( | const cfixmat & | m,
|  | const int | s
| ) |  |

inline

cfixmat + int

Definition at line 283 of file fix_operators.h.

## operator+() [32/40]

cfixmat itpp::operator+ | ( | const int | s,
|  | const cfixmat & | m
| ) |  |

inline

int + cfixmat

Definition at line 285 of file fix_operators.h.

## operator-() [31/40]

cfixmat itpp::operator- | ( | const cfixmat & | m,
|  | const int | s
| ) |  |

inline

cfixmat - int

Definition at line 287 of file fix_operators.h.

## operator-() [32/40]

cfixmat itpp::operator- | ( | const int | s,
|  | const cfixmat & | m
| ) |  |

inline

int - cfixmat

Definition at line 289 of file fix_operators.h.

## operator*() [31/40]

cfixmat itpp::operator* | ( | const cfixmat & | m,
|  | const int | s
| ) |  |

inline

cfixmat * int

Definition at line 291 of file fix_operators.h.

## operator*() [32/40]

cfixmat itpp::operator* | ( | const int | s,
|  | const cfixmat & | m
| ) |  |

inline

int * cfixmat

Definition at line 293 of file fix_operators.h.

## operator/() [18/18]

cfixmat itpp::operator/ | ( | const cfixmat & | m,
|  | const int | s
| ) |  |

inline

cfixmat / int using quantization mode `TRN`

Definition at line 295 of file fix_operators.h.

## operator+() [33/40]

ITPP_EXPORT cfixvec itpp::operator+ | ( | const cfixvec & | a,
|  | const fixvec & | b
| ) |  |

cfixvec + fixvec

Definition at line 352 of file fix_operators.cpp.

References it_assert_debug, itpp::Array< T >::size(), and itpp::Vec< Num_T >::size().

## operator+() [34/40]

cfixvec itpp::operator+ | ( | const fixvec & | a,
|  | const cfixvec & | b
| ) |  |

inline

fixvec + cfixvec

Definition at line 300 of file fix_operators.h.

## operator-() [33/40]

cfixvec itpp::operator- | ( | const cfixvec & | a,
|  | const fixvec & | b
| ) |  |

inline

cfixvec - fixvec

Definition at line 302 of file fix_operators.h.

## operator-() [34/40]

cfixvec itpp::operator- | ( | const fixvec & | a,
|  | const cfixvec & | b
| ) |  |

inline

fixvec - cfixvec

Definition at line 304 of file fix_operators.h.

## operator*() [33/40]

ITPP_EXPORT CFix itpp::operator* | ( | const cfixvec & | a,
|  | const fixvec & | b
| ) |  |

cfixvec * fixvec

Definition at line 362 of file fix_operators.cpp.

References it_assert_debug, itpp::Array< T >::size(), and itpp::Vec< Num_T >::size().

## operator*() [34/40]

CFix itpp::operator* | ( | const fixvec & | a,
|  | const cfixvec & | b
| ) |  |

inline

fixvec * cfixvec

Definition at line 308 of file fix_operators.h.

## operator+() [35/40]

ITPP_EXPORT cfixmat itpp::operator+ | ( | const cfixmat & | a,
|  | const fixmat & | b
| ) |  |

cfixmat + fixmat

Definition at line 372 of file fix_operators.cpp.

References itpp::Mat< Num_T >::cols(), it_assert_debug, and itpp::Mat< Num_T >::rows().

## operator+() [36/40]

cfixmat itpp::operator+ | ( | const fixmat & | a,
|  | const cfixmat & | b
| ) |  |

inline

fixmat + cfixmat

Definition at line 313 of file fix_operators.h.

## operator-() [35/40]

cfixmat itpp::operator- | ( | const cfixmat & | a,
|  | const fixmat & | b
| ) |  |

inline

cfixmat - fixmat

Definition at line 315 of file fix_operators.h.

## operator-() [36/40]

cfixmat itpp::operator- | ( | const fixmat & | a,
|  | const cfixmat & | b
| ) |  |

inline

fixmat - cfixmat

Definition at line 317 of file fix_operators.h.

## operator*() [35/40]

ITPP_EXPORT cfixmat itpp::operator* | ( | const cfixmat & | a,
|  | const fixmat & | b
| ) |  |

cfixmat * fixmat

Definition at line 385 of file fix_operators.cpp.

References itpp::Mat< Num_T >::_data(), itpp::Mat< Num_T >::cols(), it_assert_debug, and itpp::Mat< Num_T >::rows().

## operator*() [36/40]

cfixmat itpp::operator* | ( | const fixmat & | a,
|  | const cfixmat & | b
| ) |  |

inline

fixmat * cfixmat

Definition at line 321 of file fix_operators.h.

## operator+() [37/40]

ITPP_EXPORT cfixvec itpp::operator+ | ( | const cfixvec & | a,
|  | const ivec & | b
| ) |  |

cfixvec + ivec

Definition at line 412 of file fix_operators.cpp.

References it_assert_debug, and itpp::Array< T >::size().

## operator+() [38/40]

cfixvec itpp::operator+ | ( | const ivec & | a,
|  | const cfixvec & | b
| ) |  |

inline

ivec + cfixvec

Definition at line 326 of file fix_operators.h.

## operator-() [37/40]

cfixvec itpp::operator- | ( | const cfixvec & | a,
|  | const ivec & | b
| ) |  |

inline

cfixvec - ivec

Definition at line 328 of file fix_operators.h.

## operator-() [38/40]

cfixvec itpp::operator- | ( | const ivec & | a,
|  | const cfixvec & | b
| ) |  |

inline

ivec - cfixvec

Definition at line 330 of file fix_operators.h.

## operator*() [37/40]

ITPP_EXPORT CFix itpp::operator* | ( | const cfixvec & | a,
|  | const ivec & | b
| ) |  |

cfixvec * ivec

Definition at line 422 of file fix_operators.cpp.

References it_assert_debug, and itpp::Array< T >::size().

## operator*() [38/40]

CFix itpp::operator* | ( | const ivec & | a,
|  | const cfixvec & | b
| ) |  |

inline

ivec * cfixvec

Definition at line 334 of file fix_operators.h.

## operator+() [39/40]

ITPP_EXPORT cfixmat itpp::operator+ | ( | const cfixmat & | a,
|  | const imat & | b
| ) |  |

cfixmat + imat

Definition at line 432 of file fix_operators.cpp.

References it_assert_debug.

## operator+() [40/40]

cfixmat itpp::operator+ | ( | const imat & | a,
|  | const cfixmat & | b
| ) |  |

inline

imat + cfixmat

Definition at line 339 of file fix_operators.h.

## operator-() [39/40]

cfixmat itpp::operator- | ( | const cfixmat & | a,
|  | const imat & | b
| ) |  |

inline

cfixmat - imat

Definition at line 341 of file fix_operators.h.

## operator-() [40/40]

cfixmat itpp::operator- | ( | const imat & | a,
|  | const cfixmat & | b
| ) |  |

inline

imat - cfixmat

Definition at line 343 of file fix_operators.h.

## operator*() [39/40]

ITPP_EXPORT cfixmat itpp::operator* | ( | const cfixmat & | a,
|  | const imat & | b
| ) |  |

cfixmat * imat

Definition at line 445 of file fix_operators.cpp.

References itpp::Mat< Num_T >::_data(), itpp::Mat< Num_T >::cols(), it_assert_debug, and itpp::Mat< Num_T >::rows().

## operator*() [40/40]

cfixmat itpp::operator* | ( | const imat & | a,
|  | const cfixmat & | b
| ) |  |

inline

imat * cfixmat

Definition at line 347 of file fix_operators.h.

## set() [1/2]

void itpp::fixvec::set | ( | const char * | str | ) |

inline

Set the vector equal to the values in the `str` string.

Definition at line 814 of file vec.h.

Referenced by itpp::set_fix(), itpp::set_fix(), itpp::set_fix(), itpp::set_fix(), itpp::set_fix(), itpp::set_fix(), itpp::Vec< Num_T >::Vec(), and itpp::Vec< Num_T >::Vec().

## set() [2/2]

void itpp::fixmat::set | ( | const char * | str | ) |

inline

Set matrix equal to values in the string `str`.

Definition at line 820 of file mat.h.

## Variable Documentation

## MAX_WORDLEN

const int itpp::MAX_WORDLEN = 64

Max word length.

Definition at line 886 of file fix_base.h.

Referenced by itpp::Fix_Base::init().

## UINT64_POW2

const uint64_t itpp::UINT64_POW2[64]

Initial value:
= {
uint64_t(1), uint64_t(1) << 1, uint64_t(1) << 2, uint64_t(1) << 3, uint64_t(1) << 4,
uint64_t(1) << 5, uint64_t(1) << 6, uint64_t(1) << 7, uint64_t(1) << 8, uint64_t(1) << 9,
uint64_t(1) << 10, uint64_t(1) << 11, uint64_t(1) << 12, uint64_t(1) << 13, uint64_t(1) << 14,
uint64_t(1) << 15, uint64_t(1) << 16, uint64_t(1) << 17, uint64_t(1) << 18, uint64_t(1) << 19,
uint64_t(1) << 20, uint64_t(1) << 21, uint64_t(1) << 22, uint64_t(1) << 23, uint64_t(1) << 24,
uint64_t(1) << 25, uint64_t(1) << 26, uint64_t(1) << 27, uint64_t(1) << 28, uint64_t(1) << 29,
uint64_t(1) << 30, uint64_t(1) << 31, uint64_t(1) << 32, uint64_t(1) << 33, uint64_t(1) << 34,
uint64_t(1) << 35, uint64_t(1) << 36, uint64_t(1) << 37, uint64_t(1) << 38, uint64_t(1) << 39,
uint64_t(1) << 40, uint64_t(1) << 41, uint64_t(1) << 42, uint64_t(1) << 43, uint64_t(1) << 44,
uint64_t(1) << 45, uint64_t(1) << 46, uint64_t(1) << 47, uint64_t(1) << 48, uint64_t(1) << 49,
uint64_t(1) << 50, uint64_t(1) << 51, uint64_t(1) << 52, uint64_t(1) << 53, uint64_t(1) << 54,
uint64_t(1) << 55, uint64_t(1) << 56, uint64_t(1) << 57, uint64_t(1) << 58, uint64_t(1) << 59,
uint64_t(1) << 60, uint64_t(1) << 61, uint64_t(1) << 62, uint64_t(1) << 63
}

Table for fast multiplication or division by 2^n.

Definition at line 889 of file fix_base.h.

Referenced by itpp::Fix_Base::init().

## DOUBLE_POW2

const double itpp::DOUBLE_POW2[128]

Table for fast multiplication by 2^(n-64)

Definition at line 906 of file fix_base.h.

Referenced by itpp::Fix::operator double(), itpp::CFix::operator std::complex< double >(), itpp::Fix_Base::scale_and_apply_modes(), itpp::CFix::unfix(), and itpp::Fix::unfix().

Generated on Mon Apr 22 2024 09:45:27 for IT++ by Doxygen 1.9.8