// ---------------------------------------------------- // This file belongs to the ray tracing framework // for the use with Cherenkov detectors // // created 2012 //----------------------------------------------------- #include "PndDrcOptMatLF5G15.h" #include //#include "PndDrcOptMatAbs.h" // //#include "TObject.h" //#include "TVector3.h" //#include "TRandom.h" // #include using std::cout; using std::cerr; //using std::cin; using std::endl; // #include //#include //using std::valarray; // //#include //using std::fstream; // //#include //using std::string; // //#include //using std::list; //---------------------------------------------------------------------- PndDrcOptMatLF5G15::PndDrcOptMatLF5G15() { fName = "LF5G15"; fB1 = 1.288887331; fB2 = 0.162818811; fB3 = 10.5579792; fC1 = 0.0092001566; fC2 = 0.0456954308; fC3 = 1275.44015; } //---------------------------------------------------------------------- PndDrcOptMatLF5G15* PndDrcOptMatLF5G15::Clone() const { return new PndDrcOptMatLF5G15(*this); } //---------------------------------------------------------------------- void PndDrcOptMatLF5G15::Copy(const PndDrcOptMatLF5G15& mat) { fB1 = mat.fB1; fC1 = mat.fC1; fB2 = mat.fB2; fC2 = mat.fC2; fB3 = mat.fB3; fC3 = mat.fC3; }//---------------------------------------------------------------------- PndDrcOptMatLF5G15::PndDrcOptMatLF5G15(const PndDrcOptMatLF5G15& mat) : PndDrcOptMatAbs(mat) { if (mat.fVerbosity>=1) cout<<" PndDrcOptMatLF5G15::PndDrcOptMatLF5G15" <<"(const PndDrcOptMatLF5G15&) " <=1) cout<<" PndDrcOptMatLF5G15::operator=" <<"(const PndDrcOptMatLF5G15&) " <((*this)) = mat; // assignment of base class part. Copy(mat); } return *this; } //---------------------------------------------------------------------- double PndDrcOptMatLF5G15::RefIndex(const double lambda) const { if (lambda<0) return 1.58; // average value. double lam2 = lambda/1000 * lambda/1000; // um2 return sqrt(1.0L + fB1*lam2/(lam2-fC1) + fB2*lam2/(lam2-fC2) + fB3*lam2/(lam2-fC3)); } //---------------------------------------------------------------------- double PndDrcOptMatLF5G15::RefIndexDeriv(const double lambda) const { double lam = lambda/1000; double lam2 = lam*lam; //double lam3 = lam2*lam; return ( (-fB1*fC1*lam)/((lam2-fC1)*(lam2-fC1)) + (-fB2*fC2*lam)/((lam2-fC2)*(lam2-fC2)) + (-fB3*fC3*lam)/((lam2-fC3)*(lam2-fC3)) ) / RefIndex(lambda) / 1000; } //---------------------------------------------------------------------- bool PndDrcOptMatLF5G15::AbsorptionFlag(double lambda, double length) const { // Rayleigh scattering. // data from Schott data sheets of 10mm sample const static double kLam[16] = {1060, 700, 660, 620, 580, 546, 500, 460, 436, 420, 405, 400, 390, 380, 370, 365}; const static double kC[16] = { 9999, 3328, 2495, 1995, 1424, 1106, 661.7, 298.1, 115.4, 54.73, 23.81, 17.73, 9.525, 4.975, 2.556, 1.300}; // C = -10mm /ln (t_i) double clarity; if (lambda>1060) { clarity=9999; } else if (lambda<365) { return true; // cut off } else { // find right bin int ibin=-1; for (int i=1; i<16; i++) { if (lambda=kLam[i]) { ibin = i; } } if (ibin==-1) { cerr<<" *** PndDrcOptMatLF5G15::absorptionFlag: " <<"this line should never been hit"<Uniform(1.0); if (cmp>trans) { return true; // absorbed } return false; // no absorption. }