14 if(sigma <= 0)
return 0.;
24 if(sigma <= 0)
return 0.;
36 if(sigmax<=0 || sigmay<=0)
return 0.;
49 if(sigmax<=0 || sigmay<=0)
return 0.;
120 double zp3 = -1*xp*
QPMath::Sin(tilt) + z*(tilt) - length;
122 double sigmapx = -1* dispersion * zp3 + sigmax;
123 double sigmapy = -1* dispersion * zp3 + sigmay;
125 if(sigmapx<=0 || sigmapy<=0 )
return 0;
136 xp = x > 0 ? x : -1*x;
141 double maximum,
double meanx,
double meany,
double a,
double radius){
147 double maximum,
double meanx,
double meany,
double ax,
double ay,
double radiusX,
double radiusY){
155 double maximum,
double meanx,
double meany,
156 double ax,
double ay,
double radiusX,
double radiusY,
double rotation){
164 double maximum,
double meanx,
double meany,
165 double ax,
double ay,
double radiusX,
double radiusY,
double rotationA,
double rotationR){
185 double xp = x - centx;
186 double yp = y - centy;
197 return pow(x,exponent);
220double QPMath::Gaus(
const double& x,
const double& mean,
const double& sigma,
const bool& norm)
222 if (sigma == 0)
return 1.e30;
223 double arg = (x-mean)/sigma;
225 if (arg < -39.0 || arg > 39.0)
return 0.0;
227 if (!norm)
return res;
228 return res/(2.50662827463100024*sigma);
Dense m×n matrix of double with hand-rolled linear algebra.
QPMatrix Inverse()
Inverse by the adjugate formula .
double Det()
Determinant by recursive Laplace expansion along the first row.
3-component double vector with hand-rolled operations.
double MatrixForm2D(QPVector &x, QPVector &x0, QPMatrix &S)
2D Gaussian in covariance-matrix form,
double Simple2D(double x, double y, double integral=1., double meanx=0, double meany=0, double sigma=1.)
Isotropic 2D Gaussian .
double RotAxis2D(double x, double y, double integral=1., double meanx=0., double meany=0., double sigmax=1., double sigmay=1., double rotation=0.)
Elliptic 2D Gaussian with principal axes rotated by rotation: the offsets are first turned into the e...
double Assymetry2D(double x, double y, double integral=1., double meanx=0., double meany=0., double sigmax=1., double sigmay=1., double rotation=0., double length=0., double tilt=0., double dispersion=1.)
Gaussian of an inclined track with depth-dependent widening.
double Simple1D(double x, double integral=1., double mean=0., double sigma=1.)
1D Gaussian .
double UniAxis2D(double x, double y, double integral=1., double meanx=0., double meany=0., double sigmax=1., double sigmay=1.)
Axis-aligned elliptic 2D Gaussian .
double Angle(double x, double y, double centx=0., double centy=0.)
Quadrant-aware angle of the point (x, y) about (centx, centy).
double EllipseRotAxis(double x, double y, double lx, double ly, double theta)
Radius of the ellipse with semi-axes rotated by , evaluated in the direction of (x,...
double EllipseUniAxis(double x, double y, double lx, double ly)
EllipseRotAxis with : radius of the axis-aligned ellipse with semi-axes in the direction of (x,...
double Simple1D(double x, double maximum=1.0, double mean=0.0, double a=1.0, double radius=1.0)
1D Woods-Saxon profile .
double Simple2D(double x, double y, double maximum=1.0, double meanx=0.0, double meany=0.0, double a=1.0, double radius=1.0)
Radial 2D Woods-Saxon profile with .
double RotAxis2D(double x, double y, double maximum=1.0, double meanx=0.0, double meany=0.0, double ax=1.0, double ay=1.0, double radiusX=1.0, double radiusY=1.0, double rotation=0.0)
Elliptic 2D Woods-Saxon profile with both ellipses rotated by rotation (via GeometryCalc::EllipseRotA...
double RotAxis2DUnsync(double x, double y, double maximum=1.0, double meanx=0.0, double meany=0.0, double ax=1.0, double ay=1.0, double radiusX=1.0, double radiusY=1.0, double rotationA=0.0, double rotationR=0.0)
As RotAxis2D, but the diffuseness ellipse and the radius ellipse rotate independently.
double UniAxis2D(double x, double y, double maximum=1.0, double meanx=0.0, double meany=0.0, double ax=1.0, double ay=1.0, double radiusX=1.0, double radiusY=1.0)
Elliptic 2D Woods-Saxon profile with axis-aligned axes: where is the distance to the center and bot...
double Power(const double &x, const double &exponent)
std::pow wrapper.
double Exp(const double &x)
std::exp wrapper.
double Cos(const double &x)
std::cos wrapper.
double Sin(const double &x)
std::sin wrapper.
double ATan(const double &x)
std::atan wrapper.
double Sqrt(const double &x)
std::sqrt wrapper.
double Gaus(const double &x, const double &mean, const double &sigma, const bool &norm)
Gaussian kernel , divided by when norm is true.
double ATan2(const double &y, const double &x)
Quadrant-aware arctangent with swapped argument forwarding.
QPMatrix RotationMatrix(double theta)
Counterclockwise 2D rotation matrix.