Line data Source code
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 :
16 : /* $Id$ */
17 :
18 : // Helper class to interface pdflib and the TPythia
19 : // the c++ interface for Pythia
20 : // The pdf codes used in pdflib are mapped
21 : // to a more user friendly enumeration type.
22 : // Author: andreas.morsch@cern.ch
23 :
24 : #include "AliStructFuncType.h"
25 :
26 : #ifndef WIN32
27 : # define structa structa_
28 : # define pdfset pdfset_
29 : # define type_of_call
30 : #else
31 : # define structa STRUCTA
32 : # define pdfset PDFSET
33 : # define type_of_call _stdcall
34 : #endif
35 :
36 : extern "C" {
37 : void type_of_call pdfset(char parm[20][20], Double_t value[20]);
38 :
39 : void type_of_call structa(Double_t& xx, Double_t& qq, Double_t& a,
40 : Double_t& upv, Double_t& dnv, Double_t& usea,
41 : Double_t& dsea,
42 : Double_t& str, Double_t& chm, Double_t& bot,
43 : Double_t& top, Double_t& gl);
44 : }
45 :
46 6 : ClassImp(AliStructFuncType)
47 :
48 : void AliStructFuncType::PdfSet(char parm[20][20], Double_t value[20])
49 : {
50 0 : pdfset(parm, value);
51 0 : }
52 :
53 : void AliStructFuncType::StructA(Double_t xx, Double_t qq, Double_t a,
54 : Double_t& upv, Double_t& dnv, Double_t& usea,
55 : Double_t& dsea,
56 : Double_t& str, Double_t& chm, Double_t& bot,
57 : Double_t& top, Double_t& gl)
58 : {
59 0 : structa(xx, qq, a, upv, dnv, usea, dsea, str, chm, bot, top, gl);
60 0 : }
61 :
62 :
63 : Int_t AliStructFuncType::PDFsetIndex(StrucFunc_t pdf)
64 : {
65 : // PDF set index
66 0 : Int_t pdfSetNumber[12] = {
67 : 19170,
68 : 19150,
69 : 19070,
70 : 19050,
71 : 80060,
72 : 10040,
73 : 10100,
74 : 10050,
75 : 10041,
76 : 10042,
77 : 10800,
78 : 11000
79 : };
80 0 : return pdfSetNumber[pdf];
81 0 : }
82 :
83 : TString AliStructFuncType::PDFsetName(StrucFunc_t pdf)
84 : {
85 : // PDF Set Name
86 0 : TString pdfsetName[12] = {
87 0 : "cteq4l.LHgrid",
88 0 : "cteq4m.LHgrid",
89 0 : "cteq5l.LHgrid",
90 0 : "cteq5m.LHgrid",
91 0 : "GRV98lo.LHgrid",
92 0 : "cteq6.LHpdf",
93 0 : "cteq61.LHpdf",
94 0 : "cteq6m.LHpdf",
95 0 : "cteq6l.LHpdf",
96 0 : "cteq6ll.LHpdf",
97 0 : "CT10.LHgrid",
98 0 : "CT10nlo.LHgrid"
99 : };
100 0 : return pdfsetName[pdf];
101 0 : }
|