2 #ifndef __JPHYSICS__ANTARES__ 
    3 #define __JPHYSICS__ANTARES__ 
   66       static const double a0 = 1.0;
 
   69       zmap[610.0] = a0/0.2890;
 
   70       zmap[600.0] = a0/0.2440;
 
   71       zmap[590.0] = a0/0.1570;
 
   72       zmap[580.0] = a0/0.1080;
 
   73       zmap[570.0] = a0/0.0799;
 
   74       zmap[560.0] = a0/0.0708;
 
   75       zmap[550.0] = a0/0.0638;
 
   76       zmap[540.0] = a0/0.0558;
 
   77       zmap[530.0] = a0/0.0507;
 
   78       zmap[520.0] = a0/0.0477;
 
   79       zmap[510.0] = a0/0.0357;
 
   80       zmap[500.0] = a0/0.0257;
 
   81       zmap[490.0] = a0/0.0196;
 
   82       zmap[480.0] = a0/0.0182;
 
   83       zmap[470.0] = a0/0.0182;
 
   84       zmap[460.0] = a0/0.0191;
 
   85       zmap[450.0] = a0/0.0200;
 
   86       zmap[440.0] = a0/0.0218;
 
   87       zmap[430.0] = a0/0.0237;
 
   88       zmap[420.0] = a0/0.0255;
 
   89       zmap[410.0] = a0/0.0291;
 
   90       zmap[400.0] = a0/0.0325;
 
   91       zmap[390.0] = a0/0.0363;
 
   92       zmap[380.0] = a0/0.0415;
 
   93       zmap[370.0] = a0/0.0473;
 
   94       zmap[360.0] = a0/0.0528;
 
   95       zmap[350.0] = a0/0.0629;
 
   96       zmap[340.0] = a0/0.0710;
 
   97       zmap[330.0] = a0/0.0792;
 
   98       zmap[320.0] = a0/0.0946;
 
   99       zmap[310.0] = a0/0.1090;
 
  100       zmap[300.0] = a0/0.1390;
 
  104     const double x = lambda;
 
  106     if (x > zmap.begin()->first && x < zmap.rbegin()->first) {
 
  108       map_t::const_iterator i = zmap.lower_bound(x);
 
  109       map_t::const_iterator 
j = i;
 
  113       if (i == zmap.begin()) {
 
  118       const double x1 = i->first;
 
  119       const double x2 = j->first;
 
  121       const double y1 = i->second;
 
  122       const double y2 = j->second;
 
  124       return y1  +  (y2 - y1) * (x - x1) / (x2 - x1);
 
  147       zmap[307.0] =   19.7132;
 
  148       zmap[330.0] =   23.8280;
 
  149       zmap[350.0] =   27.6075;
 
  150       zmap[370.0] =   31.5448;
 
  151       zmap[390.0] =   35.6151;
 
  152       zmap[410.0] =   39.7971;
 
  153       zmap[430.0] =   44.0726;
 
  154       zmap[450.0] =   48.4261;
 
  155       zmap[470.0] =   52.8447;
 
  156       zmap[490.0] =   57.3172;
 
  157       zmap[510.0] =   61.8344;
 
  158       zmap[530.0] =   66.3884;
 
  159       zmap[550.0] =   70.9723;
 
  160       zmap[570.0] =   75.5804;
 
  161       zmap[590.0] =   80.2077;
 
  162       zmap[610.0] =   84.8497;
 
  166     const double x = lambda;
 
  168     if (x > zmap.begin()->first && x < zmap.rbegin()->first) {
 
  170       map_t::const_iterator i = zmap.lower_bound(x);
 
  171       map_t::const_iterator 
j = i;
 
  175       if (i == zmap.begin()) {
 
  180       const double x1 = i->first;
 
  181       const double x2 = j->first;
 
  183       const double y1 = i->second;
 
  184       const double y2 = j->second;
 
  186       return y1  +  (y2 - y1) * (x - x1) / (x2 - x1);
 
  205     const double a0 = (1.0 - g*g) / (4*
PI);
 
  206     const double y  =  1.0 + g*g - 2.0*g*x;
 
  208     return a0 / (y*sqrt(y));
 
  220     static const double g = 0.924;
 
  237     const double a0 = 1.0 / (1.0 + a/3.0) / (4*
PI);
 
  239     return a0 * (1.0 + a*x*x); 
 
  261   inline double f4(
const double x)
 
  263     static const double g1 = 0.77;
 
  264     static const double g2 = 0.00;
 
  265     static const double f  = 1.00;
 
  279     static const double g = 0.924;
 
  280     static const double f = 0.17;
 
  306     static const double a0 =  0.3265;
 
  307     static const double a1 =  0.6144;
 
  308     static const double a2 = -0.0343;
 
  309     static const double a3 = -0.0641;
 
  310     static const double a4 =  0.2988;
 
  311     static const double a5 = -0.1422;
 
  320       y = a0 + z*(a1 + z*(a2 + z*(a3 + z*(a4 + z*a5))));
 
  334     static const double a0 = 59.115;
 
  335     static const double a1 =  0.52258;
 
  336     static const double a2 =  0.60944E-02;
 
  337     static const double a3 = -0.16955E-03;
 
  338     static const double a4 =  0.60929E-06;
 
  348       const double z = acos(-x)*57.29578 + 57.75;
 
  350       y = (a0 + z*(a1 + z*(a2 + z*(a3 + z*a4)))) / 84.0;
 
  376   inline double getQE(
const double lambda, 
const bool option)
 
  380       tuple(
const double __QE,
 
  381             const double __l_gel,
 
  382             const double __l_glass) :
 
  393     static const tuple ntuple[] = {
 
  394       tuple(0.000e-2,   0.00,   0.00),
 
  395       tuple(1.988e-2, 100.81, 148.37),
 
  396       tuple(2.714e-2,  99.94, 142.87),
 
  397       tuple(3.496e-2,  99.89, 135.64),
 
  398       tuple(4.347e-2,  96.90, 134.58),
 
  399       tuple(5.166e-2,  96.42, 138.27),
 
  400       tuple(6.004e-2,  94.36, 142.40),
 
  401       tuple(6.885e-2,  89.09, 147.16),
 
  402       tuple(8.105e-2,  90.10, 151.80),
 
  403       tuple(10.13e-2,  86.95, 150.88),
 
  404       tuple(13.03e-2,  85.88, 145.68),
 
  405       tuple(15.29e-2,  84.49, 139.70),
 
  406       tuple(16.37e-2,  81.08, 126.55),
 
  407       tuple(17.11e-2,  78.18, 118.86),
 
  408       tuple(17.86e-2,  76.48, 113.90),
 
  409       tuple(18.95e-2,  74.55, 116.08),
 
  410       tuple(20.22e-2,  72.31, 109.23),
 
  411       tuple(21.26e-2,  68.05,  81.63),
 
  412       tuple(22.10e-2,  66.91,  65.66),
 
  413       tuple(22.65e-2,  64.48,  77.30),
 
  414       tuple(23.07e-2,  62.53,  73.02),
 
  415       tuple(23.14e-2,  59.38,  81.25),
 
  416       tuple(23.34e-2,  56.64, 128.04),
 
  417       tuple(22.95e-2,  53.29,  61.84),
 
  418       tuple(22.95e-2,  48.96,  19.23),
 
  419       tuple(22.74e-2,  45.71,  27.21),
 
  420       tuple(23.48e-2,  41.88,  18.09),
 
  421       tuple(22.59e-2,  37.14,   8.41),
 
  422       tuple(20.61e-2,  30.49,   3.92),
 
  423       tuple(17.68e-2,  23.08,   1.82),
 
  424       tuple(13.18e-2,  15.60,   0.84),
 
  425       tuple(7.443e-2,   8.00,   0.39),
 
  426       tuple(2.526e-2,   0.00,   0.17),
 
  427       tuple(0.000e-2,   0.00,   0.00)
 
  430     static const double cola    = 0.9;      
 
  431     static const double x_glass = 1.5;      
 
  432     static const double x_gel   = 1.0;      
 
  435     static const int    N    = 
sizeof(ntuple) / 
sizeof(ntuple[0])  -  1;
 
  437     static const double xmax = 620.0;       
 
  438     static const double xmin = 290.0;       
 
  440     const double x = lambda;
 
  444     if (x > xmin && x < xmax) {
 
  446       const int i = (int) (N * (x - xmax) / (xmin - xmax));
 
  447       const int j = (i == N ? i - 1 : i + 1); 
 
  449       const double x1 = xmax  +  i * (xmin - xmax) / N;
 
  450       const double x2 = xmax  +  j * (xmin - xmax) / N;
 
  452       const double dx = (x - x1) / (x1 - x2);
 
  454       const double QE      = ntuple[i].QE       +  (ntuple[i].QE      - ntuple[
j].QE     ) * dx;
 
  455       const double l_gel   = ntuple[i].l_gel    +  (ntuple[i].l_gel   - ntuple[
j].l_gel  ) * dx;
 
  456       const double l_glass = ntuple[i].l_glass  +  (ntuple[i].l_glass - ntuple[
j].l_glass) * dx;
 
  462         if (l_glass > 0.0 && l_gel > 0.0)
 
  463           y *= 
exp(-x_glass/l_glass) * 
exp(-x_gel/l_gel);
 
  479   inline double getQE(
const double lambda)
 
  481     return getQE(lambda, 
true);
 
const double getPhotocathodeArea()
Photo-cathode area 10 inch PMT. 
 
double getPhotocathodeArea2D(const double x, const double lambda)
Photo-cathode area 10 inch PMT. 
 
double getQE(const double lambda, const bool option)
Quantum efficiency of 10-inch Hamamatsu PMT. 
 
double gamelle(const double x)
Angular acceptence of Antares PMT (Gamelle) 
 
double f4(const double x)
Model specific function to describe light scattering in water (f4) 
 
double getScatteringProbability(const double x)
Function to describe light scattering in water. 
 
then fatal Wrong number of arguments fi set_variable DETECTOR $argv[1] set_variable STRING $argv[2] set_array QUANTILES set_variable FORMULA *[0] exp(-0.5 *(x-[1])*(x-[1])/([2]*[2]))" set_variable MODULE `getModule -a $DETECTOR -L "$STRING 0"` typeset -Z 4 STRING JOpera1D -f hydrophone.root
 
double getAmbientPressure()
Get ambient pressure. 
 
static const double PI
Mathematical constants. 
 
double henyey_greenstein(const double g, const double x)
Auxiliary method to describe light scattering in water (Heneyey-Greenstein) 
 
double p00075(const double x)
Model specific function to describe light scattering in water (p00075) 
 
double getAbsorptionLength(const double lambda)
Absoption length. 
 
double getScatteringLength(const double lambda)
Scattering length. 
 
double getAngularAcceptance(const double x)
Angular acceptence of Antares PMT. 
 
then usage $script[input file[working directory[option]]] nWhere option can be N
 
double rayleigh(const double a, const double x)
Auxiliary method to describe light scattering in water (Rayleigh) 
 
double genova(const double x)
Angular acceptence of Antares PMT (Genova) 
 
Double_t g1(const Double_t x)
Function.