BornAgain  1.18.0
Simulate and fit neutron and x-ray scattering at grazing incidence
MathFunctions.h File Reference

Defines namespace MathFunctions. More...

Go to the source code of this file.

Namespaces

 MathFunctions
 Various mathematical functions.
 

Enumerations

enum  EFFTDirection { FORWARD_FFT , BACKWARD_FFT }
 

Functions

double MathFunctions::StandardNormal (double x)
 
double MathFunctions::Gaussian (double x, double average, double std_dev)
 
double MathFunctions::IntegratedGaussian (double x, double average, double std_dev)
 
double MathFunctions::cot (double x)
 cotangent function: $cot(x)\equiv1/tan(x)$
 
double MathFunctions::Si (double x)
 Sine integral function: $Si(x)\equiv\int_0^x du \sin(u)/u$.
 
double MathFunctions::sinc (double x)
 sinc function: $sinc(x)\equiv\sin(x)/x$
 
complex_t MathFunctions::sinc (const complex_t z)
 Complex sinc function: $sinc(x)\equiv\sin(x)/x$.
 
complex_t MathFunctions::tanhc (const complex_t z)
 Complex tanhc function: $tanhc(x)\equiv\tanh(x)/x$.
 
double MathFunctions::Laue (const double x, size_t N)
 Real Laue function: $Laue(x,N)\equiv\sin(Nx)/sin(x)$.
 
double MathFunctions::erf (double arg)
 Error function of real-valued argument.
 
double MathFunctions::Bessel_J0 (double x)
 Bessel function of the first kind and order 0.
 
double MathFunctions::Bessel_J1 (double x)
 Bessel function of the first kind and order 1.
 
double MathFunctions::Bessel_J1c (double x)
 Bessel function Bessel_J1(x)/x.
 
double MathFunctions::Bessel_I0 (double x)
 Modified Bessel function of the first kind and order 0.
 
complex_t MathFunctions::Bessel_J0 (const complex_t z)
 Complex Bessel function of the first kind and order 0.
 
complex_t MathFunctions::Bessel_J1 (const complex_t z)
 Complex Bessel function of the first kind and order 1.
 
complex_t MathFunctions::Bessel_J1c (const complex_t z)
 Complex Bessel function Bessel_J1(x)/x.
 
std::vector< complex_t > MathFunctions::FastFourierTransform (const std::vector< complex_t > &data, EFFTDirection tcase)
 simple (and unoptimized) wrapper function for the discrete fast Fourier transformation library (fftw3)
 
std::vector< complex_t > MathFunctions::FastFourierTransform (const std::vector< double > &data, EFFTDirection tcase)
 simple (and unoptimized) wrapper function for the discrete fast Fourier transformation library (fftw3); transforms real to complex
 
std::vector< complex_t > MathFunctions::ConvolveFFT (const std::vector< double > &signal, const std::vector< double > &resfunc)
 convolution of two real vectors of equal size
 
double MathFunctions::GenerateUniformRandom ()
 
double MathFunctions::GenerateStandardNormalRandom ()
 
double MathFunctions::GenerateNormalRandom (double average, double std_dev)
 
double MathFunctions::GeneratePoissonRandom (double average)
 

Detailed Description

Defines namespace MathFunctions.

Homepage:\n http://www.bornagainproject.org
License:\n GNU General Public License v3 or higher (see COPYING)
Authors
Scientific Computing Group at MLZ (see CITATION, AUTHORS)

Definition in file MathFunctions.h.