IT++ Logo Newcom Logo

Miscellaneous Functions


Functions

itpp::vec itpp::gamma (const itpp::vec &x)
 The gamma function.
itpp::mat itpp::gamma (const itpp::mat &x)
 The gamma function.
vec itpp::ceil (const vec &x)
 Round to nearest upper integer.
mat itpp::ceil (const mat &x)
 Round to nearest upper integer.
vec itpp::floor (const vec &x)
 Round to nearest lower integer.
mat itpp::floor (const mat &x)
 Round to nearest lower integer.
vec itpp::round (const vec &x)
 Round to nearest integer.
mat itpp::round (const mat &x)
 Round to nearest integer.
ivec itpp::round_i (const vec &x)
 Round to nearest integer and return ivec.
imat itpp::round_i (const mat &x)
 Round to nearest integer and return imat.
vec itpp::abs (const vec &x)
 Absolute value.
mat itpp::abs (const mat &x)
 Absolute value.
ivec itpp::abs (const ivec &x)
 Absolute value.
imat itpp::abs (const imat &x)
 Absolute value.
vec itpp::sqr (const vec &x)
 Square of elements.
mat itpp::sqr (const mat &x)
 Square of elements.
vec itpp::sqr (const cvec &x)
 Square of elements.
mat itpp::sqr (const cmat &x)
 Square of elements.
vec itpp::sign (const vec &x)
 Signum function.
mat itpp::sign (const mat &x)
 Signum function.
vec itpp::sqrt (const vec &x)
 Square root of the elements.
mat itpp::sqrt (const mat &x)
 Square root of the elements.
vec itpp::rem (const vec &x, const double &y)
 Elementwise reminder of the division x/y for vec and double.
vec itpp::rem (const double &x, const vec &y)
 Elementwise reminder of the division x/y for double and vec.
mat itpp::rem (const mat &x, const double &y)
 Elementwise reminder of the division x/y for mat and double.
mat itpp::rem (const double &x, const mat &y)
 Elementwise reminder of the division x/y for double and mat.
vec itpp::abs (const cvec &x)
 Absolute value.
mat itpp::abs (const cmat &x)
 Absolute value.
vec itpp::real (const cvec &x)
 Real part of complex values.
mat itpp::real (const cmat &x)
 Real part of complex values.
vec itpp::imag (const cvec &x)
 Imaginary part of complex values.
mat itpp::imag (const cmat &x)
 Imaginary part of complex values.
vec itpp::arg (const cvec &x)
 Argument (angle).
mat itpp::arg (const cmat &x)
 Argument (angle).
vec itpp::angle (const cvec &x)
 Angle.
mat itpp::angle (const cmat &x)
 Angle.
cvec itpp::conj (const cvec &x)
 Conjugate of complex value.
cmat itpp::conj (const cmat &x)
 Conjugate of complex value.
bool itpp::all (const Vec< bin > &testvec)
 Returns true if all elements are ones and false otherwise.
bool itpp::any (const Vec< bin > &testvec)
 Returns true if any element is one and false otherwise.
vec itpp::round_to_zero (const vec &x, double threshold=1e-14)
 Round each element to zero if element < threshold.
mat itpp::round_to_zero (const mat &x, double threshold=1e-14)
 Round each element to zero if element < threshold.
cvec itpp::round_to_zero (const cvec &x, double threshold=1e-14)
 Round each element to zero if element < threshold.
cmat itpp::round_to_zero (const cmat &x, double threshold=1e-14)
 Round each element to zero if element < threshold.
vec itpp::vec_function (double(*f)(double), const vec &x)
 Help function to call for a function: vec function(vec).
cvec itpp::cvec_function (std::complex< double >(*f)(const std::complex< double > &), const cvec &x)
 Help function to call for a function: cvec function(cvec).
mat itpp::mat_function (double(*f)(double), const mat &x)
 Help function to call for a function: mat function(mat).
cmat itpp::cmat_function (std::complex< double >(*f)(const std::complex< double > &), const cmat &x)
 Help function to call for a function: cmat function(cmat).
vec itpp::double_vec_function (double(*f)(double, double), const double x, const vec &y)
 Help function to call for a function: vec function(double,vec).
mat itpp::double_mat_function (double(*f)(double, double), const double x, const mat &y)
 Help function to call for a function: mat function(double,mat).
vec itpp::vec_double_function (double(*f)(double, double), const vec &x, const double y)
 Help function to call for a function: vec function(vec,double).
mat itpp::mat_double_function (double(*f)(double, double), const mat &x, const double y)
 Help function to call for a function: mat function(mat,double).
double asinh (double x)
 Arcus sinhyp.
double acosh (double x)
 Arcus coshyp.
double atanh (double x)
 Arcus tanhyp.
double tgamma (double x)
 True gamma function.
double lgamma (double x)
 Lograrithm of an absolute gamma function.
double itpp::gamma (double x)
 Gamma function.
double itpp::sinc (double x)
 Sinc function. sinc(x) = sin(pi*x)/pi*x.
int itpp::round_i (double x)
 Round to nearest integer.
int itpp::ceil_i (double x)
 The nearest larger integer.
int itpp::floor_i (double x)
 The nearest smaller integer.
double itpp::round (double x)
 Round to nearest integer, return result in double.
bool itpp::is_int (double x)
 Return true if x is an integer.
bool itpp::is_even (int x)
 Return true if x is an even integer.
int itpp::gray_code (int x)
 Convert to Gray Code.
double itpp::binom (int n, int k)
 Compute the binomial coefficient "n over k" as a float.
int itpp::binom_i (int n, int k)
 Compute the binomial coefficient "n over k" as an integer.
double itpp::log_binom (int n, int k)
 Compute the base 10 logarithm of the binomial coefficient "n over k".
double itpp::rad_to_deg (double x)
 Convert radians to degrees.
double itpp::deg_to_rad (double x)
 Convert degrees to radians.
double itpp::sqr (double x)
 Square of x.
double itpp::sqr (std::complex< double > x)
 Square of complex-valued x, ||x||^2.
double itpp::rem (double x, double y)
 The reminder of the division x/y.
double itpp::sign (double x)
 The sign of x.
double itpp::sgn (double x)
 The sign of x.
signed char itpp::abs (signed char x)
 Absolute value.
short itpp::abs (short x)
 Absolute value.
int itpp::abs (int x)
 Absolute value.
double itpp::fact (int index)
 Calculates factorial coefficient for index <= 170.
long itpp::mod (long k, long n)
 Calculates the modulus, i.e. the signed reminder after division.
long itpp::gcd (long a, long b)
 returns the greatest common divisor (GCD) g of the elements a and b.
double itpp::round_to_zero (double x, double threshold=1e-14)
 Round x to zero if abs(x) is smaller than threshold.
std::complex< double > itpp::round_to_zero (const std::complex< double > &x, double threshold=1e-14)
 Round each part of x smaller than threshold to zero.
ivec itpp::find (const bvec &invector)
 Return a integer vector with indicies where bvec == 1.
mat itpp::rotation_matrix (int dim, int plane1, int plane2, double angle)
 Create a rotation matrix that rotates the given plane angle radians. Note that the order of the planes are important!
void itpp::house (const vec &x, vec &v, double &beta)
 Calcualte the Householder vector.
void itpp::givens (double a, double b, double &c, double &s)
 Calculate the Givens rotation values.
void itpp::givens (double a, double b, mat &m)
 Calculate the Givens rotation matrix.
mat itpp::givens (double a, double b)
 Calculate the Givens rotation matrix.
void itpp::givens_t (double a, double b, mat &m)
 Calculate the transposed Givens rotation matrix.
mat itpp::givens_t (double a, double b)
 Calculate the transposed Givens rotation matrix.
bmat itpp::graycode (int m)
 Generate gray code of blocklength m.
int itpp::hamming_distance (const bvec &a, const bvec &b)
 Calculate the Hamming distance between a and b.
int itpp::weight (const bvec &a)
 Calculate the Hamming weight of a.
smat itpp::wcdma_spreading_codes (int SF)
 Generates the OVSF (orthogonal variable spreading factor) spreading codes used in WCDMA.

Detailed Description


Function Documentation

itpp::vec itpp::gamma ( const itpp::vec &  x  )  [inline]

The gamma function.

Definition at line 48 of file elmatfunc.h.

References itpp::vec_function().

Referenced by itpp::gamma(), and itpp::Weibull_RNG::setup().

itpp::mat itpp::gamma ( const itpp::mat &  x  )  [inline]

The gamma function.

Definition at line 54 of file elmatfunc.h.

References itpp::gamma(), and itpp::mat_function().

vec itpp::ceil ( const vec x  )  [inline]

Round to nearest upper integer.

Definition at line 222 of file elmatfunc.h.

References itpp::ceil(), and itpp::vec_function().

Referenced by itpp::bin2oct(), itpp::ceil_i(), and itpp::round().

mat itpp::ceil ( const mat x  )  [inline]

Round to nearest upper integer.

Definition at line 224 of file elmatfunc.h.

References itpp::mat_function().

Referenced by itpp::ceil(), itpp::Sequence_Interleaver< T >::deinterleave(), itpp::Cross_Interleaver< T >::deinterleave(), itpp::Block_Interleaver< T >::deinterleave(), itpp::IFFT_Fading_Generator::generate_Jakes(), itpp::Sequence_Interleaver< T >::interleave(), itpp::Cross_Interleaver< T >::interleave(), itpp::Block_Interleaver< T >::interleave(), itpp::Fix_Base::scale_and_apply_modes(), and itpp::xcorr().

vec itpp::floor ( const vec x  )  [inline]

Round to nearest lower integer.

Definition at line 226 of file elmatfunc.h.

References itpp::floor(), and itpp::vec_function().

Referenced by itpp::Reed_Solomon::decode(), itpp::Hamming_Code::decode(), itpp::Extended_Golay::decode(), itpp::BCH::decode(), itpp::Reed_Solomon::encode(), itpp::Hamming_Code::encode(), itpp::Extended_Golay::encode(), itpp::BCH::encode(), itpp::floor_i(), and itpp::mod().

mat itpp::floor ( const mat x  )  [inline]

Round to nearest lower integer.

Definition at line 228 of file elmatfunc.h.

References itpp::mat_function().

Referenced by itpp::Multicode_Spread_1d::despread(), itpp::Spread_1d::despread(), itpp::floor(), itpp::jake_filter(), itpp::Fix_Base::scale_and_apply_modes(), itpp::Multicode_Spread_1d::spread(), and itpp::LLR_calc_unit::to_qllr().

vec itpp::round ( const vec x  )  [inline]

Round to nearest integer.

Definition at line 231 of file elmatfunc.h.

References itpp::vec_function().

Referenced by fpica(), itpp::round(), itpp::round_i(), itpp::Fix_Base::scale_and_apply_modes(), itpp::sd(), and itpp::TDL_Channel::set_channel_profile().

mat itpp::round ( const mat x  )  [inline]

Round to nearest integer.

Definition at line 233 of file elmatfunc.h.

References itpp::mat_function(), and itpp::round().

ivec itpp::round_i ( const vec x  )  [inline]

Round to nearest integer and return ivec.

Definition at line 236 of file elmatfunc.h.

References itpp::round(), and itpp::to_ivec().

Referenced by itpp::Cross_Interleaver< T >::deinterleave(), itpp::QAM::demodulate_bits(), itpp::PSK::demodulate_bits(), itpp::PAM::demodulate_bits(), itpp::Modulator_1d::set(), itpp::ND_UPAM::set_Gray_PAM(), itpp::ND_UPSK::set_Gray_PSK(), itpp::ND_UQAM::set_Gray_QAM(), itpp::QAM::set_M(), itpp::PSK::set_M(), itpp::PAM::set_M(), itpp::GF::set_size(), and itpp::sqtrain().

imat itpp::round_i ( const mat x  )  [inline]

Round to nearest integer and return imat.

Definition at line 238 of file elmatfunc.h.

References itpp::round(), and itpp::to_imat().

vec itpp::abs ( const vec x  )  [inline]

Absolute value.

Definition at line 242 of file elmatfunc.h.

References itpp::vec_function().

mat itpp::abs ( const mat x  )  [inline]

Absolute value.

Definition at line 244 of file elmatfunc.h.

References itpp::mat_function().

ivec itpp::abs ( const ivec data  ) 

Absolute value.

Definition at line 60 of file elmatfunc.cpp.

References itpp::abs().

Referenced by itpp::cerf_series(), itpp::cerfc_continued_fraction(), itpp::diag(), itpp::erf(), itpp::filter_spectrum(), fpica(), itpp::norm(), itpp::polystab(), itpp::sd(), itpp::Newton_Search::search(), itpp::spectrum(), itpp::within_tolerance(), and itpp::xcorr().

imat itpp::abs ( const imat data  ) 

Absolute value.

Definition at line 70 of file elmatfunc.cpp.

References itpp::abs().

vec itpp::sqr ( const vec x  )  [inline]

Square of elements.

Definition at line 250 of file elmatfunc.h.

References itpp::sqr(), and itpp::vec_function().

mat itpp::sqr ( const mat x  )  [inline]

Square of elements.

Definition at line 252 of file elmatfunc.h.

References itpp::mat_function(), and itpp::sqr().

vec itpp::sqr ( const cvec x  ) 

Square of elements.

Definition at line 38 of file elmatfunc.cpp.

Referenced by itpp::TDL_Channel::calc_mean_excess_delay(), itpp::TDL_Channel::calc_rms_delay_spread(), itpp::Channel_Specification::calc_rms_delay_spread(), itpp::QAM::demodulate_soft_bits(), itpp::PSK::demodulate_soft_bits(), itpp::PAM::demodulate_soft_bits(), itpp::Modulator_2d::demodulate_soft_bits(), itpp::QAM::demodulate_soft_bits_approx(), itpp::PSK::demodulate_soft_bits_approx(), itpp::PAM::demodulate_soft_bits_approx(), itpp::Modulator_2d::demodulate_soft_bits_approx(), itpp::energy(), itpp::filter_design_autocorrelation(), itpp::filter_spectrum(), itpp::AWGN_Channel::get_noise(), itpp::gmmtrain(), itpp::house(), itpp::kmeansiter(), itpp::GMM::likelihood_aposteriori(), itpp::Modulator_NCD::map_demod(), itpp::Modulator_NRD::map_demod(), itpp::norm(), itpp::poly2ac(), itpp::sd(), itpp::Line_Search::search(), itpp::Channel_Specification::set_channel_profile(), itpp::PAM::set_M(), itpp::Root_Raised_Cosine< T1 >::set_pulse_shape(), itpp::Raised_Cosine< T1 >::set_pulse_shape(), itpp::spectrum(), itpp::sqr(), itpp::Modulator_NCD::update_norm(), itpp::Modulator_NRD::update_norm(), and itpp::vqtrain().

mat itpp::sqr ( const cmat x  ) 

Square of elements.

Definition at line 47 of file elmatfunc.cpp.

References itpp::sqr().

vec itpp::sign ( const vec x  )  [inline]

Signum function.

Definition at line 258 of file elmatfunc.h.

References itpp::vec_function().

Referenced by itpp::quadl(), itpp::Vec< Num_T >::set(), and itpp::sign().

mat itpp::sign ( const mat x  )  [inline]

Signum function.

Definition at line 260 of file elmatfunc.h.

References itpp::mat_function(), and itpp::sign().

vec itpp::sqrt ( const vec x  )  [inline]

Square root of the elements.

Definition at line 263 of file elmatfunc.h.

References itpp::sqrt(), and itpp::vec_function().

Referenced by itpp::cerf_series(), itpp::cerfc_continued_fraction(), itpp::GMM::draw_sample(), itpp::erfinv(), itpp::quadl(), itpp::quadlstep(), itpp::Turbo_Codec::set_awgn_channel_parameters(), and itpp::Rec_Syst_Conv_Code::set_awgn_channel_parameters().

mat itpp::sqrt ( const mat x  )  [inline]

Square root of the elements.

Definition at line 265 of file elmatfunc.h.

References itpp::mat_function().

Referenced by acosh(), asinh(), itpp::AWGN_Channel::AWGN_Channel(), itpp::TDL_Channel::calc_rms_delay_spread(), itpp::Channel_Specification::calc_rms_delay_spread(), itpp::QPSK::demodulate_soft_bits(), itpp::dht(), itpp::IFFT_Fading_Generator::generate(), itpp::FIR_Fading_Generator::generate(), itpp::Rice_Fading_Generator::generate(), itpp::IFFT_Fading_Generator::generate_Jakes(), itpp::Fading_Generator::generate_zero_doppler(), itpp::givens(), itpp::givens_t(), itpp::gmmtrain(), itpp::house(), itpp::Rice_Fading_Generator::init_MEDS(), itpp::jake_filter(), itpp::norm(), itpp::quadl(), itpp::Complex_Normal_RNG::sample(), itpp::Laplace_RNG::sample(), itpp::Normal_RNG::sample(), itpp::sd(), itpp::Newton_Search::search(), itpp::self_dht(), itpp::ND_UPAM::set_Gray_PAM(), itpp::ND_UQAM::set_Gray_QAM(), itpp::QAM::set_M(), itpp::PAM::set_M(), itpp::AWGN_Channel::set_noise(), itpp::Root_Raised_Cosine< T1 >::set_pulse_shape(), itpp::Complex_Normal_RNG::setup(), itpp::Normal_RNG::setup(), itpp::Stat::sigma(), itpp::sqrt(), itpp::sqrt_win(), itpp::sqrtm(), whitenv(), itpp::xcorr(), and itpp::xcorr_old().

vec itpp::rem ( const vec x,
const double &  y 
) [inline]

Elementwise reminder of the division x/y for vec and double.

Definition at line 270 of file elmatfunc.h.

References itpp::vec_double_function().

Referenced by itpp::rem().

vec itpp::rem ( const double &  x,
const vec y 
) [inline]

Elementwise reminder of the division x/y for double and vec.

Definition at line 272 of file elmatfunc.h.

References itpp::double_vec_function(), and itpp::rem().

mat itpp::rem ( const mat x,
const double &  y 
) [inline]

Elementwise reminder of the division x/y for mat and double.

Definition at line 274 of file elmatfunc.h.

References itpp::mat_double_function(), and itpp::rem().

mat itpp::rem ( const double &  x,
const mat y 
) [inline]

Elementwise reminder of the division x/y for double and mat.

Definition at line 276 of file elmatfunc.h.

References itpp::double_mat_function(), and itpp::rem().

vec itpp::abs ( const cvec data  ) 

Absolute value.

Definition at line 83 of file elmatfunc.cpp.

References itpp::abs().

mat itpp::abs ( const cmat data  ) 

Absolute value.

Definition at line 93 of file elmatfunc.cpp.

References itpp::abs().

vec itpp::real ( const cvec data  ) 

Real part of complex values.

Definition at line 106 of file elmatfunc.cpp.

Referenced by itpp::arma_estimator(), itpp::cmat2mxArray(), itpp::Multicode_Spread_2d::despread(), itpp::Spread_2d::despread(), itpp::it_file::low_level_write(), itpp::norm(), itpp::CFixed< w, e, o, q >::operator=(), itpp::Freq_Filt< Num_T >::overlap_add(), itpp::polystab(), itpp::set_fix(), itpp::Multicode_Spread_2d::spread(), itpp::Spread_2d::spread(), itpp::to(), itpp::to_cmat(), itpp::to_cvec(), itpp::Modulator_NCD::update_norm(), and itpp::xcorr().

mat itpp::real ( const cmat data  ) 

Real part of complex values.

Definition at line 116 of file elmatfunc.cpp.

vec itpp::imag ( const cvec data  ) 

Imaginary part of complex values.

Definition at line 129 of file elmatfunc.cpp.

Referenced by itpp::cmat2mxArray(), itpp::Multicode_Spread_2d::despread(), itpp::Spread_2d::despread(), itpp::CFixed< w, e, o, q >::operator=(), itpp::set_fix(), itpp::Multicode_Spread_2d::spread(), itpp::Spread_2d::spread(), itpp::to(), itpp::to_cmat(), and itpp::to_cvec().

mat itpp::imag ( const cmat data  ) 

Imaginary part of complex values.

Definition at line 138 of file elmatfunc.cpp.

vec itpp::arg ( const cvec data  ) 

Argument (angle).

Definition at line 151 of file elmatfunc.cpp.

References itpp::arg().

Referenced by itpp::angle().

mat itpp::arg ( const cmat data  ) 

Argument (angle).

Definition at line 161 of file elmatfunc.cpp.

Referenced by itpp::arg(), and itpp::PSK::demodulate_bits().

vec itpp::angle ( const cvec x  )  [inline]

Angle.

Definition at line 295 of file elmatfunc.h.

References itpp::arg().

mat itpp::angle ( const cmat x  )  [inline]

Angle.

Definition at line 297 of file elmatfunc.h.

References itpp::arg().

cvec itpp::conj ( const cvec data  ) 

Conjugate of complex value.

Definition at line 174 of file elmatfunc.cpp.

References itpp::conj().

Referenced by itpp::Modulator_NCD::map_demod(), itpp::polystab(), itpp::sqrtm(), itpp::toeplitz(), itpp::Modulator_NCD::update_norm(), and itpp::xcorr().

cmat itpp::conj ( const cmat data  ) 

Conjugate of complex value.

Definition at line 184 of file elmatfunc.cpp.

References itpp::conj().

bool itpp::all ( const Vec< bin > &  testvec  ) 

Returns true if all elements are ones and false otherwise.

Definition at line 197 of file elmatfunc.cpp.

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

bool itpp::any ( const Vec< bin > &  testvec  ) 

Returns true if any element is one and false otherwise.

Definition at line 204 of file elmatfunc.cpp.

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

Referenced by itpp::levinson(), itpp::poly2ac(), itpp::poly2rc(), and itpp::rc2poly().

vec itpp::round_to_zero ( const vec x,
double  threshold = 1e-14 
) [inline]

Round each element to zero if element < threshold.

Definition at line 309 of file elmatfunc.h.

References itpp::round_to_zero(), and itpp::vec_double_function().

mat itpp::round_to_zero ( const mat x,
double  threshold = 1e-14 
) [inline]

Round each element to zero if element < threshold.

Definition at line 313 of file elmatfunc.h.

References itpp::mat_double_function(), and itpp::round_to_zero().

cvec itpp::round_to_zero ( const cvec x,
double  threshold = 1e-14 
)

Round each element to zero if element < threshold.

Definition at line 211 of file elmatfunc.cpp.

Referenced by itpp::round_to_zero().

cmat itpp::round_to_zero ( const cmat x,
double  threshold = 1e-14 
)

Round each element to zero if element < threshold.

Definition at line 220 of file elmatfunc.cpp.

References itpp::round_to_zero().

vec itpp::vec_function ( double(*)(double)  f,
const vec x 
) [inline]

Help function to call for a function: vec function(vec).

Definition at line 46 of file help_functions.h.

Referenced by itpp::abs(), itpp::acos(), itpp::acosh(), itpp::asin(), itpp::asinh(), itpp::atan(), itpp::atanh(), itpp::ceil(), itpp::cos(), itpp::cosh(), itpp::dB(), itpp::erf(), itpp::erfc(), itpp::erfinv(), itpp::exp(), itpp::floor(), itpp::gamma(), itpp::inv_dB(), itpp::log(), itpp::log10(), itpp::log2(), itpp::pow10(), itpp::pow2(), itpp::Qfunc(), itpp::quad(), itpp::quadl(), itpp::quadlstep(), itpp::quadstep(), itpp::round(), itpp::sign(), itpp::sin(), itpp::sinc(), itpp::sinh(), itpp::sqr(), itpp::sqrt(), itpp::tan(), and itpp::tanh().

cvec itpp::cvec_function ( std::complex< double >(*)(const std::complex< double > &)  f,
const cvec x 
) [inline]

Help function to call for a function: cvec function(cvec).

Definition at line 58 of file help_functions.h.

Referenced by itpp::erf(), itpp::exp(), and itpp::log().

mat itpp::mat_function ( double(*)(double)  f,
const mat x 
) [inline]

Help function to call for a function: mat function(mat).

Definition at line 70 of file help_functions.h.

Referenced by itpp::abs(), itpp::acos(), itpp::acosh(), itpp::asin(), itpp::asinh(), itpp::atan(), itpp::atanh(), itpp::ceil(), itpp::cos(), itpp::cosh(), itpp::dB(), itpp::erf(), itpp::erfc(), itpp::erfinv(), itpp::exp(), itpp::floor(), itpp::gamma(), itpp::inv_dB(), itpp::log(), itpp::log10(), itpp::log2(), itpp::pow10(), itpp::pow2(), itpp::Qfunc(), itpp::round(), itpp::sign(), itpp::sin(), itpp::sinc(), itpp::sinh(), itpp::sqr(), itpp::sqrt(), itpp::tan(), and itpp::tanh().

cmat itpp::cmat_function ( std::complex< double >(*)(const std::complex< double > &)  f,
const cmat x 
) [inline]

Help function to call for a function: cmat function(cmat).

Definition at line 85 of file help_functions.h.

Referenced by itpp::erf(), itpp::exp(), and itpp::log().

vec itpp::double_vec_function ( double(*)(double, double)  f,
const double  x,
const vec y 
) [inline]

Help function to call for a function: vec function(double,vec).

Definition at line 100 of file help_functions.h.

Referenced by itpp::logb(), itpp::pow(), and itpp::rem().

mat itpp::double_mat_function ( double(*)(double, double)  f,
const double  x,
const mat y 
) [inline]

Help function to call for a function: mat function(double,mat).

Definition at line 112 of file help_functions.h.

Referenced by itpp::logb(), itpp::pow(), and itpp::rem().

vec itpp::vec_double_function ( double(*)(double, double)  f,
const vec x,
const double  y 
) [inline]

Help function to call for a function: vec function(vec,double).

Definition at line 127 of file help_functions.h.

Referenced by itpp::pow(), itpp::rem(), and itpp::round_to_zero().

mat itpp::mat_double_function ( double(*)(double, double)  f,
const mat x,
const double  y 
) [inline]

Help function to call for a function: mat function(mat,double).

Definition at line 139 of file help_functions.h.

Referenced by itpp::pow(), itpp::rem(), and itpp::round_to_zero().

double asinh ( double  x  ) 

Arcus sinhyp.

Definition at line 75 of file scalfunc.cpp.

References itpp::log(), and itpp::sqrt().

double acosh ( double  x  ) 

Arcus coshyp.

Definition at line 82 of file scalfunc.cpp.

References it_error_if, itpp::log(), and itpp::sqrt().

double atanh ( double  x  ) 

Arcus tanhyp.

Definition at line 90 of file scalfunc.cpp.

References it_error_if, and itpp::log().

double tgamma ( double  x  ) 

True gamma function.

Definition at line 41 of file scalfunc.cpp.

References itpp::exp(), and itpp::log().

Referenced by itpp::gamma(), and lgamma().

double lgamma ( double  x  ) 

Lograrithm of an absolute gamma function.

Definition at line 58 of file scalfunc.cpp.

References itpp::log(), signgam, and tgamma().

double itpp::gamma ( double  x  ) 

Gamma function.

Definition at line 182 of file scalfunc.cpp.

References tgamma().

double itpp::sinc ( double  x  )  [inline]

Sinc function. sinc(x) = sin(pi*x)/pi*x.

Definition at line 226 of file scalfunc.h.

References itpp::pi, and itpp::sin().

int itpp::round_i ( double  x  )  [inline]

Round to nearest integer.

Definition at line 237 of file scalfunc.h.

int itpp::ceil_i ( double  x  )  [inline]

The nearest larger integer.

Definition at line 239 of file scalfunc.h.

References itpp::ceil().

Referenced by itpp::FIR_Fading_Generator::generate(), and itpp::needed_bits().

int itpp::floor_i ( double  x  )  [inline]

The nearest smaller integer.

Definition at line 241 of file scalfunc.h.

References itpp::floor().

Referenced by itpp::filter_design_autocorrelation(), itpp::I_Uniform_RNG::sample(), and itpp::GF2mat::T_fact().

double itpp::round ( double  x  )  [inline]

Round to nearest integer, return result in double.

Definition at line 244 of file scalfunc.h.

bool itpp::is_int ( double  x  )  [inline]

Return true if x is an integer.

Definition at line 247 of file scalfunc.h.

bool itpp::is_even ( int  x  )  [inline]

Return true if x is an even integer.

Definition at line 250 of file scalfunc.h.

Referenced by itpp::Modulator_2d::set(), itpp::QAM::set_M(), itpp::Root_Raised_Cosine< T1 >::set_pulse_shape(), and itpp::Raised_Cosine< T1 >::set_pulse_shape().

int itpp::gray_code ( int  x  )  [inline]

Convert to Gray Code.

Definition at line 314 of file scalfunc.h.

Referenced by itpp::ND_UQAM::set_Gray_QAM(), and itpp::QAM::set_M().

double itpp::binom ( int  n,
int  k 
)

Compute the binomial coefficient "n over k" as a float.

Definition at line 407 of file scalfunc.cpp.

References it_assert.

int itpp::binom_i ( int  n,
int  k 
)

Compute the binomial coefficient "n over k" as an integer.

Definition at line 422 of file scalfunc.cpp.

References it_assert.

double itpp::log_binom ( int  n,
int  k 
)

Compute the base 10 logarithm of the binomial coefficient "n over k".

Definition at line 437 of file scalfunc.cpp.

References it_assert, and itpp::log10().

double itpp::rad_to_deg ( double  x  )  [inline]

Convert radians to degrees.

Definition at line 326 of file scalfunc.h.

References itpp::pi.

double itpp::deg_to_rad ( double  x  )  [inline]

Convert degrees to radians.

Definition at line 328 of file scalfunc.h.

References itpp::pi.

double itpp::sqr ( double  x  )  [inline]

Square of x.

Definition at line 336 of file scalfunc.h.

double itpp::sqr ( std::complex< double >  x  )  [inline]

Square of complex-valued x, ||x||^2.

Definition at line 338 of file scalfunc.h.

double itpp::rem ( double  x,
double  y 
) [inline]

The reminder of the division x/y.

Definition at line 340 of file scalfunc.h.

double itpp::sign ( double  x  )  [inline]

The sign of x.

Definition at line 342 of file scalfunc.h.

double itpp::sgn ( double  x  )  [inline]

The sign of x.

Definition at line 344 of file scalfunc.h.

Referenced by itpp::erfinv().

signed char itpp::abs ( signed char  x  )  [inline]

Absolute value.

Definition at line 347 of file scalfunc.h.

short itpp::abs ( short  x  )  [inline]

Absolute value.

Definition at line 349 of file scalfunc.h.

int itpp::abs ( int  x  )  [inline]

Absolute value.

Definition at line 351 of file scalfunc.h.

double itpp::fact ( int  index  ) 

Calculates factorial coefficient for index <= 170.

Definition at line 368 of file scalfunc.cpp.

References it_error_if, and itpp::prod().

long itpp::mod ( long  k,
long  n 
)

Calculates the modulus, i.e. the signed reminder after division.

Definition at line 378 of file scalfunc.cpp.

References itpp::floor().

Referenced by fpica(), itpp::operator<<(), and itpp::wcdma_turbo_interleaver_sequence().

long itpp::gcd ( long  a,
long  b 
)

returns the greatest common divisor (GCD) g of the elements a and b.

a and b must be non-negative integers. gdc(0,0) is 0 by convention; all other GCDs are positive integers.

Definition at line 387 of file scalfunc.cpp.

References itpp::abs(), and it_assert.

Referenced by itpp::wcdma_turbo_interleaver_sequence().

double itpp::round_to_zero ( double  x,
double  threshold = 1e-14 
) [inline]

Round x to zero if abs(x) is smaller than threshold.

Definition at line 370 of file scalfunc.h.

References itpp::abs().

std::complex< double > itpp::round_to_zero ( const std::complex< double > &  x,
double  threshold = 1e-14 
)

Round each part of x smaller than threshold to zero.

Definition at line 450 of file scalfunc.cpp.

References itpp::round_to_zero().

ivec itpp::find ( const bvec invector  ) 

Return a integer vector with indicies where bvec == 1.

Definition at line 41 of file specmat.cpp.

References it_assert.

Referenced by itpp::roots().

mat itpp::rotation_matrix ( int  dim,
int  plane1,
int  plane2,
double  angle 
)

Create a rotation matrix that rotates the given plane angle radians. Note that the order of the planes are important!

Definition at line 265 of file specmat.cpp.

References itpp::cos(), it_assert, and itpp::sin().

void itpp::house ( const vec x,
vec v,
double &  beta 
)

Calcualte the Householder vector.

Definition at line 287 of file specmat.cpp.

References itpp::energy(), itpp::sqr(), and itpp::sqrt().

void itpp::givens ( double  a,
double  b,
double &  c,
double &  s 
)

Calculate the Givens rotation values.

Definition at line 313 of file specmat.cpp.

References itpp::sqrt().

Referenced by itpp::givens().

void itpp::givens ( double  a,
double  b,
mat m 
)

Calculate the Givens rotation matrix.

Definition at line 335 of file specmat.cpp.

References itpp::sqrt().

mat itpp::givens ( double  a,
double  b 
)

Calculate the Givens rotation matrix.

Definition at line 365 of file specmat.cpp.

References itpp::givens().

void itpp::givens_t ( double  a,
double  b,
mat m 
)

Calculate the transposed Givens rotation matrix.

Definition at line 373 of file specmat.cpp.

References itpp::sqrt().

Referenced by itpp::givens_t().

mat itpp::givens_t ( double  a,
double  b 
)

Calculate the transposed Givens rotation matrix.

Definition at line 403 of file specmat.cpp.

References itpp::givens_t().

bmat itpp::graycode ( int  m  ) 

Generate gray code of blocklength m.

The codes are contained as binary codewords {0,1} in the rows of the returned matrix. See also the gray() function in math/scalfunc.h.

Definition at line 42 of file commfunc.cpp.

References itpp::concat(), itpp::ones_b(), itpp::reverse(), itpp::to_bmat(), and itpp::zeros_b().

Referenced by itpp::ND_UPAM::set_Gray_PAM(), itpp::ND_UPSK::set_Gray_PSK(), itpp::ND_UQAM::set_Gray_QAM(), itpp::QAM::set_M(), itpp::PSK::set_M(), and itpp::PAM::set_M().

int itpp::hamming_distance ( const bvec a,
const bvec b 
)

Calculate the Hamming distance between a and b.

Definition at line 61 of file commfunc.cpp.

References it_assert1.

int itpp::weight ( const bvec a  ) 

Calculate the Hamming weight of a.

Definition at line 73 of file commfunc.cpp.

Referenced by itpp::Extended_Golay::decode().

smat itpp::wcdma_spreading_codes ( int  SF  ) 

Generates the OVSF (orthogonal variable spreading factor) spreading codes used in WCDMA.

The codes are written row-wise in the return matrix.

Definition at line 170 of file sequence.cpp.

References itpp::concat(), and it_assert.

SourceForge Logo

Generated on Fri Jun 8 00:37:36 2007 for IT++ by Doxygen 1.5.2