]> git.uio.no Git - u/mrichter/AliRoot.git/blame - EVGEN/AliPartonicEnergyLoss.cxx
Log replaced by Id
[u/mrichter/AliRoot.git] / EVGEN / AliPartonicEnergyLoss.cxx
CommitLineData
3432b7c0 1/**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
3 * *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
6 * *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
15
803d1ab0 16/* $Id$ */
3432b7c0 17
18#include "AliPartonicEnergyLoss.h"
19#include <TMath.h>
20
21
22#ifndef WIN32
23# define lookup lookup_
24# define read read_
25# define readca3 readca3_
26# define type_of_call
27#else
28# define lookup LOOKUP
29# define read READ
30# define readca3 READCA3
31# define type_of_call _stdcall
32#endif
33
34
35extern "C" void type_of_call lookup(Double_t &, Double_t &,
36 Double_t &, Double_t &);
37extern "C" void type_of_call read();
38extern "C" void type_of_call readca3();
39
40
41ClassImp(AliPartonicEnergyLoss)
42
43void AliPartonicEnergyLoss::
44QuenchingWeight(Double_t r, Double_t x, Double_t& cont, Double_t& disc)
45{
46//
47// Calculate quenching weight
48//
49 lookup(r,x,cont,disc);
50}
51
52void AliPartonicEnergyLoss::RunTest()
53{
54//
55// Test routine
56//
57 Double_t cont, disc, rri, wwt;
58
59 Init();
60
61 rri = 400.;
62 for (Int_t i = 1; i <= 40; i++)
63 {
64 wwt = TMath::Power(10., (-3.+5.*(i-1)/49.));
65 QuenchingWeight(rri,wwt,cont,disc);
66 printf("%d %e %e\n", i, wwt, cont);
67 }
68}
69
70void AliPartonicEnergyLoss::Init()
71{
72//
73// Read data
74//
75 read();
76 readca3();
77}
78