1 /**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
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 **************************************************************************/
19 // Calculate parton energy loss
21 // reactions via calculation
22 // of quenching weights
26 #include "AliPartonicEnergyLoss.h"
31 # define eloss_lookup eloss_lookup_
32 # define eloss_read eloss_read_
33 # define eloss_readca3 eloss_readca3_
36 # define eloss_lookup ELOSS_LOOKUP
37 # define eloss_read ELOSS_READ
38 # define eloss_readca3 ELOSS_READCA3
39 # define type_of_call _stdcall
43 extern "C" void type_of_call eloss_lookup(Double_t &, Double_t &,
44 Double_t &, Double_t &);
45 extern "C" void type_of_call eloss_read();
46 extern "C" void type_of_call eloss_readca3();
49 ClassImp(AliPartonicEnergyLoss)
51 void AliPartonicEnergyLoss::
52 QuenchingWeight(Double_t r, Double_t x, Double_t& cont, Double_t& disc)
55 // Calculate quenching weight
57 eloss_lookup(r,x,cont,disc);
60 void AliPartonicEnergyLoss::RunTest()
65 Double_t cont, disc, rri, wwt;
70 for (Int_t i = 1; i <= 40; i++)
72 wwt = TMath::Power(10., (-3.+5.*(i-1)/49.));
73 QuenchingWeight(rri,wwt,cont,disc);
74 printf("%d %e %e\n", i, wwt, cont);
78 void AliPartonicEnergyLoss::Init()