![]() |
ROOT 6.07/09 Reference Guide |
Class describing a Vavilov distribution.
The probability density function of the Vavilov distribution as function of Landau's parameter is given by:
\[ p(\lambda_L; \kappa, \beta^2) = \frac{1}{2 \pi i}\int_{c-i\infty}^{c+i\infty} \phi(s) e^{\lambda_L s} ds\]
where \(\phi(s) = e^{C} e^{\psi(s)}\) with \( C = \kappa (1+\beta^2 \gamma )\) and \(\psi(s)= s \ln \kappa + (s+\beta^2 \kappa) \cdot \left ( \int \limits_{0}^{1} \frac{1 - e^{\frac{-st}{\kappa}}}{t} \,d t- \gamma \right ) - \kappa \, e^{\frac{-s}{\kappa}}\). \( \gamma = 0.5772156649\dots\) is Euler's constant.
For the class VavilovFast, Pdf returns the Vavilov distribution as function of Landau's parameter \(\lambda_L = \lambda_V/\kappa - \ln \kappa\), which is the convention used in the CERNLIB routines, and in the tables by S.M. Seltzer and M.J. Berger: Energy loss stragglin of protons and mesons: Tabulation of the Vavilov distribution, pp 187-203 in: National Research Council (U.S.), Committee on Nuclear Science: Studies in penetration of charged particles in matter, Nat. Akad. Sci. Publication 1133, Nucl. Sci. Series Report No. 39, Washington (Nat. Akad. Sci.) 1964, 388 pp. Available from Google books
Therefore, for small values of \(\kappa < 0.01\), pdf approaches the Landau distribution.
For values \(\kappa > 10\), the Gauss approximation should be used with \(\mu\) and \(\sigma\) given by Vavilov::mean(kappa, beta2) and sqrt(Vavilov::variance(kappa, beta2).
For values \(\kappa > 10\), the Gauss approximation should be used with \(\mu\) and \(\sigma\) given by Vavilov::mean(kappa, beta2) and sqrt(Vavilov::variance(kappa, beta2).
The original Vavilov pdf is obtained by v.Pdf(lambdaV/kappa-log(kappa))/kappa.
For detailed description see A. Rotondi and P. Montagna, Fast calculation of Vavilov distribution, Nucl. Instr. and Meth. B47 (1990) 215-224, which has been implemented in CERNLIB (G115).
The class stores coefficients needed to calculate \(p(\lambda; \kappa, \beta^2)\) for fixed values of \(\kappa\) and \(\beta^2\). Changing these values is computationally expensive.
The parameter \(\kappa\) must be in the range \(0.01 \le \kappa \le 12\).
The parameter \(\beta^2\) must be in the range \(0 \le \beta^2 \le 1\).
Average times on a Pentium Core2 Duo P8400 2.26GHz:
Benno List, June 2010
Definition at line 116 of file VavilovFast.h.
Public Member Functions | |
VavilovFast (double kappa=1, double beta2=1) | |
Initialize an object to calculate the Vavilov distribution. More... | |
virtual | ~VavilovFast () |
Destructor. More... | |
double | Cdf (double x) const |
Evaluate the Vavilov cumulative probability density function. More... | |
double | Cdf (double x, double kappa, double beta2) |
Evaluate the Vavilov cumulative probability density function, and set kappa and beta2, if necessary. More... | |
double | Cdf_c (double x) const |
Evaluate the Vavilov complementary cumulative probability density function. More... | |
double | Cdf_c (double x, double kappa, double beta2) |
Evaluate the Vavilov complementary cumulative probability density function, and set kappa and beta2, if necessary. More... | |
virtual double | GetBeta2 () const |
Return the current value of \(\beta^2\). More... | |
virtual double | GetKappa () const |
Return the current value of \(\kappa\). More... | |
virtual double | GetLambdaMax () const |
Return the maximum value of \(\lambda\) for which \(p(\lambda; \kappa, \beta^2)\) is nonzero in the current approximation. More... | |
virtual double | GetLambdaMin () const |
Return the minimum value of \(\lambda\) for which \(p(\lambda; \kappa, \beta^2)\) is nonzero in the current approximation. More... | |
double | Pdf (double x) const |
Evaluate the Vavilov probability density function. More... | |
double | Pdf (double x, double kappa, double beta2) |
Evaluate the Vavilov probability density function, and set kappa and beta2, if necessary. More... | |
double | Quantile (double z) const |
Evaluate the inverse of the Vavilov cumulative probability density function. More... | |
double | Quantile (double z, double kappa, double beta2) |
Evaluate the inverse of the Vavilov cumulative probability density function, and set kappa and beta2, if necessary. More... | |
double | Quantile_c (double z) const |
Evaluate the inverse of the complementary Vavilov cumulative probability density function. More... | |
double | Quantile_c (double z, double kappa, double beta2) |
Evaluate the inverse of the complementary Vavilov cumulative probability density function, and set kappa and beta2, if necessary. More... | |
virtual void | SetKappaBeta2 (double kappa, double beta2) |
Change \(\kappa\) and \(\beta^2\) and recalculate coefficients if necessary. More... | |
![]() | |
Vavilov () | |
Default constructor. More... | |
virtual | ~Vavilov () |
Destructor. More... | |
virtual double | Kurtosis () const |
Return the theoretical kurtosis \(\gamma_2 = \frac{1/3 - \beta^2/4}{\kappa^3 \sigma^4}\). More... | |
virtual double | Mean () const |
Return the theoretical mean \(\mu = \gamma-1- \ln \kappa - \beta^2\), where \(\gamma = 0.5772\dots\) is Euler's constant. More... | |
virtual double | Mode () const |
Return the value of \(\lambda\) where the pdf is maximal. More... | |
virtual double | Mode (double kappa, double beta2) |
Return the value of \(\lambda\) where the pdf is maximal function, and set kappa and beta2, if necessary. More... | |
virtual double | Skewness () const |
Return the theoretical skewness \(\gamma_1 = \frac{1/2 - \beta^2/3}{\kappa^2 \sigma^3} \). More... | |
virtual double | Variance () const |
Return the theoretical variance \(\sigma^2 = \frac{1 - \beta^2/2}{\kappa}\). More... | |
Static Public Member Functions | |
static VavilovFast * | GetInstance () |
Returns a static instance of class VavilovFast. More... | |
static VavilovFast * | GetInstance (double kappa, double beta2) |
Returns a static instance of class VavilovFast, and sets the values of kappa and beta2. More... | |
![]() | |
static double | Kurtosis (double kappa, double beta2) |
Return the theoretical kurtosis \(\gamma_2 = \frac{1/3 - \beta^2/4}{\kappa^3 \sigma^4}\). More... | |
static double | Mean (double kappa, double beta2) |
Return the theoretical Mean \(\mu = \gamma-1- \ln \kappa - \beta^2\). More... | |
static double | Skewness (double kappa, double beta2) |
Return the theoretical skewness \(\gamma_1 = \frac{1/2 - \beta^2/3}{\kappa^2 \sigma^3} \). More... | |
static double | Variance (double kappa, double beta2) |
Return the theoretical Variance \(\sigma^2 = \frac{1 - \beta^2/2}{\kappa}\). More... | |
Private Attributes | |
double | fAC [14] |
double | fBeta2 |
double | fHC [9] |
int | fItype |
double | fKappa |
int | fNpt |
double | fWCM [201] |
Static Private Attributes | |
static VavilovFast * | fgInstance = 0 |
#include <Math/VavilovFast.h>
ROOT::Math::VavilovFast::VavilovFast | ( | double | kappa = 1 , |
double | beta2 = 1 |
||
) |
Initialize an object to calculate the Vavilov distribution.
kappa | The parameter \(\kappa\), which must be in the range \(0.01 \le \kappa \le 12 \) |
beta2 | The parameter \(\beta^2\), which must be in the range \(0 \le \beta^2 \le 1 \) |
Definition at line 52 of file VavilovFast.cxx.
|
virtual |
Destructor.
Definition at line 58 of file VavilovFast.cxx.
|
virtual |
Evaluate the Vavilov cumulative probability density function.
x | The Landau parameter \(x = \lambda_L\) |
Implements ROOT::Math::Vavilov.
Definition at line 426 of file VavilovFast.cxx.
|
virtual |
Evaluate the Vavilov cumulative probability density function, and set kappa and beta2, if necessary.
x | The Landau parameter \(x = \lambda_L\) |
kappa | The parameter \(\kappa\), which must be in the range \(0.01 \le \kappa \le 12 \) |
beta2 | The parameter \(\beta^2\), which must be in the range \(0 \le \beta^2 \le 1 \) |
Implements ROOT::Math::Vavilov.
Definition at line 444 of file VavilovFast.cxx.
|
virtual |
Evaluate the Vavilov complementary cumulative probability density function.
x | The Landau parameter \(x = \lambda_L\) |
Implements ROOT::Math::Vavilov.
Definition at line 440 of file VavilovFast.cxx.
|
virtual |
Evaluate the Vavilov complementary cumulative probability density function, and set kappa and beta2, if necessary.
x | The Landau parameter \(x = \lambda_L\) |
kappa | The parameter \(\kappa\), which must be in the range \(0.01 \le \kappa \le 12 \) |
beta2 | The parameter \(\beta^2\), which must be in the range \(0 \le \beta^2 \le 1 \) |
Implements ROOT::Math::Vavilov.
Definition at line 462 of file VavilovFast.cxx.
|
virtual |
Return the current value of \(\beta^2\).
Implements ROOT::Math::Vavilov.
Definition at line 563 of file VavilovFast.cxx.
|
static |
Returns a static instance of class VavilovFast.
Definition at line 567 of file VavilovFast.cxx.
|
static |
Returns a static instance of class VavilovFast, and sets the values of kappa and beta2.
kappa | The parameter \(\kappa\), which must be in the range \(0.01 \le \kappa \le 12 \) |
beta2 | The parameter \(\beta^2\), which must be in the range \(0 \le \beta^2 \le 1 \) |
Definition at line 572 of file VavilovFast.cxx.
|
virtual |
Return the current value of \(\kappa\).
Implements ROOT::Math::Vavilov.
Definition at line 559 of file VavilovFast.cxx.
|
virtual |
Return the maximum value of \(\lambda\) for which \(p(\lambda; \kappa, \beta^2)\) is nonzero in the current approximation.
Implements ROOT::Math::Vavilov.
Definition at line 555 of file VavilovFast.cxx.
|
virtual |
Return the minimum value of \(\lambda\) for which \(p(\lambda; \kappa, \beta^2)\) is nonzero in the current approximation.
Implements ROOT::Math::Vavilov.
Definition at line 551 of file VavilovFast.cxx.
|
virtual |
Evaluate the Vavilov probability density function.
x | The Landau parameter \(x = \lambda_L\) |
Implements ROOT::Math::Vavilov.
Definition at line 364 of file VavilovFast.cxx.
|
virtual |
Evaluate the Vavilov probability density function, and set kappa and beta2, if necessary.
x | The Landau parameter \(x = \lambda_L\) |
kappa | The parameter \(\kappa\), which must be in the range \(0.01 \le \kappa \le 12 \) |
beta2 | The parameter \(\beta^2\), which must be in the range \(0 \le \beta^2 \le 1 \) |
Implements ROOT::Math::Vavilov.
Definition at line 408 of file VavilovFast.cxx.
|
virtual |
Evaluate the inverse of the Vavilov cumulative probability density function.
z | The argument \(z\), which must be in the range \(0 \le z \le 1\) |
Implements ROOT::Math::Vavilov.
Definition at line 480 of file VavilovFast.cxx.
|
virtual |
Evaluate the inverse of the Vavilov cumulative probability density function, and set kappa and beta2, if necessary.
z | The argument \(z\), which must be in the range \(0 \le z \le 1\) |
kappa | The parameter \(\kappa\), which must be in the range \(0.01 \le \kappa \le 12 \) |
beta2 | The parameter \(\beta^2\), which must be in the range \(0 \le \beta^2 \le 1 \) |
Implements ROOT::Math::Vavilov.
Definition at line 536 of file VavilovFast.cxx.
|
virtual |
Evaluate the inverse of the complementary Vavilov cumulative probability density function.
z | The argument \(z\), which must be in the range \(0 \le z \le 1\) |
Implements ROOT::Math::Vavilov.
Definition at line 541 of file VavilovFast.cxx.
|
virtual |
Evaluate the inverse of the complementary Vavilov cumulative probability density function, and set kappa and beta2, if necessary.
z | The argument \(z\), which must be in the range \(0 \le z \le 1\) |
kappa | The parameter \(\kappa\), which must be in the range \(0.01 \le \kappa \le 12 \) |
beta2 | The parameter \(\beta^2\), which must be in the range \(0 \le \beta^2 \le 1 \) |
Implements ROOT::Math::Vavilov.
Definition at line 546 of file VavilovFast.cxx.
|
virtual |
Change \(\kappa\) and \(\beta^2\) and recalculate coefficients if necessary.
kappa | The parameter \(\kappa\), which must be in the range \(0.01 \le \kappa \le 12 \) |
beta2 | The parameter \(\beta^2\), which must be in the range \(0 \le \beta^2 \le 1 \) |
Implements ROOT::Math::Vavilov.
Definition at line 63 of file VavilovFast.cxx.
|
private |
Definition at line 273 of file VavilovFast.h.
|
private |
Definition at line 271 of file VavilovFast.h.
|
staticprivate |
Definition at line 279 of file VavilovFast.h.
|
private |
Definition at line 274 of file VavilovFast.h.
|
private |
Definition at line 276 of file VavilovFast.h.
|
private |
Definition at line 270 of file VavilovFast.h.
|
private |
Definition at line 277 of file VavilovFast.h.
|
private |
Definition at line 275 of file VavilovFast.h.