# Project CMSSW displayed by LXR

File indexing completed on 2021-02-14 14:25:06

```0001 //
0002 //  VVIObj.h (v2.0)
0003 //
0004 //  Vavilov density and distribution functions
0005 //
0006 //
0007 // Created by Morris Swartz on 1/14/10.
0008 // 2010 __TheJohnsHopkinsUniversity__.
0009 //
0010 // V1.1 - make dzero call both fcns with a switch
0011 // V1.2 - remove inappriate initializers and add methods to return non-zero/normalized region
0012 // V2.0 - restructuring and speed improvements by V. Innocente
0013 //
0014
0015 #ifndef VVIObj_h
0016 #define VVIObj_h 1
0017
0018 // ***********************************************************************************************************************
0019 //! \class VVIObj
0020 //!
0021 //!  Port of CERNLIB routines vvidis/vviden (G116) to calculate higher quality Vavilov density and distribution functions
0022 //!
0023 // ***********************************************************************************************************************
0024 class VVIObj {
0025 public:
0026   VVIObj(double kappa = 0.01, double beta2 = 1., int mode = 0);  //!< Constructor
0027
0028   double fcn(double x) const;  //! density (mode=0) or distribution (mode=1) function
0029   void limits(double& xl,
0030               double& xu) const;  //! returns the limits on the non-zero (mode=0) or normalized region (mode=1)
0031
0032 private:
0033   // Vavilov distribution parameters (inputs and common block /G116C1/)
0034
0035   const int mode_;  //!< set to 0 to calculate the density function and to 1 to calculate the distribution function
0036   double t0_;
0037   double t1_;
0038   double t_;
0039   double omega_;
0040   double x0_;
0041   double a_[155];
0042   double b_[155];
0043 };
0044
0045 #endif```