15 #ifndef BORNAGAIN_BASE_UTILS_MATHFUNCTIONS_H
16 #define BORNAGAIN_BASE_UTILS_MATHFUNCTIONS_H
31 double Gaussian(
double x,
double average,
double std_dev);
41 double sinc(
double x);
50 double Laue(
const double x,
size_t N);
53 double erf(
double arg);
93 std::vector<complex_t>
ConvolveFFT(
const std::vector<double>& signal,
94 const std::vector<double>& resfunc);
Defines complex_t, and a few elementary functions.
std::complex< double > complex_t
Various mathematical functions.
double GenerateUniformRandom()
double IntegratedGaussian(double x, double average, double std_dev)
double GenerateNormalRandom(double average, double std_dev)
double cot(double x)
cotangent function:
std::vector< complex_t > FastFourierTransform(const std::vector< complex_t > &data, EFFTDirection tcase)
simple (and unoptimized) wrapper function for the discrete fast Fourier transformation library (fftw3...
double Laue(const double x, size_t N)
Real Laue function: .
std::vector< complex_t > ConvolveFFT(const std::vector< double > &signal, const std::vector< double > &resfunc)
convolution of two real vectors of equal size
double sinc(double x)
sinc function:
double StandardNormal(double x)
complex_t tanhc(const complex_t z)
Complex tanhc function: .
double Bessel_J0(double x)
Bessel function of the first kind and order 0.
double Bessel_J1(double x)
Bessel function of the first kind and order 1.
double Bessel_J1c(double x)
Bessel function Bessel_J1(x)/x.
double Gaussian(double x, double average, double std_dev)
double erf(double arg)
Error function of real-valued argument.
double Si(double x)
Sine integral function: .
double GeneratePoissonRandom(double average)
double Bessel_I0(double x)
Modified Bessel function of the first kind and order 0.
double GenerateStandardNormalRandom()