-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathtestDetectorR5.C
161 lines (122 loc) · 5.19 KB
/
testDetectorR5.C
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
// You have to load the class before ... ;-)
// .L DetectorK.cxx++
//void standardPlots() {
void testDetectorR5(float mass = 0.0005, float ptmin = 0.05) {
if (gClassTable->GetID("DetectorK")<0) {
gROOT->ProcessLine(".L DetectorK.cxx+");
}
DetectorK its("ALICE","ITS");
its.SetBField(0.2);
// new ideal Pixel properties?
Double_t x0IB = 0.0005;
Double_t x0OB = 0.005;
Double_t xrhoIB = 1.1646e-02; // 50 mum Si
Double_t xrhoOB = 1.1646e-01; // 500 mum Si
Double_t resRPhiIB = 0.0001;
Double_t resZIB = 0.0001;
Double_t resRPhiOB = 0.0005;
Double_t resZOB = 0.0005;
Double_t eff = 0.98;
//
/*
its.AddLayer((char*)"ddd1", 2.32 , x0IB, xrhoIB, resRPhiIB, resZIB,eff);
its.AddLayer((char*)"ddd2", 3.13 , x0IB, xrhoIB, resRPhiIB, resZIB,eff);
its.AddLayer((char*)"ddd3", 3.91 , x0IB, xrhoIB, resRPhiIB, resZIB,eff);
its.AddLayer((char*)"ddd4", 19.41, x0OB, xrhoOB, resRPhiOB, resZOB,eff);
its.AddLayer((char*)"ddd5", 24.71 , x0OB, xrhoOB, resRPhiOB, resZOB,eff);
its.AddLayer((char*)"ddd6", 35.33 , x0OB, xrhoOB, resRPhiOB, resZOB,eff);
its.AddLayer((char*)"ddd7", 40.53 , x0OB, xrhoOB, resRPhiOB, resZOB,eff);
its.AddLayer((char*)"dddZ", 90.53 , x0OB, xrhoOB, resRPhiOB, resZOB,eff);
its.AddLayer((char*)"dddY", 95.0 , x0OB, xrhoOB, resRPhiOB, resZOB,eff);
its.AddLayer((char*)"dddX", 100.0 , x0OB, xrhoOB, resRPhiOB, resZOB,eff);
*/
its.AddLayer((char*)"vertex", 0, 0); // dummy vertex for matrix calculation
its.AddLayer((char*)"bpipe",1.6, 0.0014, 9.24e-02 ); // 500 mum Be | nominal R5?
//its.AddLayer((char*)"bpipe",2.0.0, 0.0022, 1.478e-1); // 800 mum Be
/*
its.AddLayer((char*)"ddd1", 2.3 , x0IB, xrhoIB, resRPhiIB, resZIB,eff);
its.AddLayer((char*)"ddd2", 3.5 , x0IB, xrhoIB, resRPhiIB, resZIB,eff);
its.AddLayer((char*)"ddd3", 5 , x0IB, xrhoIB, resRPhiIB, resZIB,eff);
*/
///*
its.AddLayer((char*)"ddd1", 1.8 , x0IB, xrhoIB, resRPhiIB, resZIB,eff);
its.AddLayer((char*)"ddd2", 2.8 , x0IB, xrhoIB, resRPhiIB, resZIB,eff);
//its.AddLayer((char*)"bpipe", 2.9 , 0.0014, 9.24e-02 ); // 500 mum Be
its.AddLayer((char*)"ddd3", 3.8 , x0IB, xrhoIB, resRPhiIB, resZIB,eff);
// */
its.AddLayer((char*)"ddd3a", 8, x0OB, xrhoOB, resRPhiOB, resZOB,eff);
its.AddLayer((char*)"ddd4", 20., x0OB, xrhoOB, resRPhiOB, resZOB,eff);
its.AddLayer((char*)"ddd5", 25 , x0OB, xrhoOB, resRPhiOB, resZOB,eff);
// its.AddLayer((char*)"ddd6", 35. , x0OB, xrhoOB, resRPhiOB, resZOB,eff);
its.AddLayer((char*)"ddd7", 40. , x0OB, xrhoOB, resRPhiOB, resZOB,eff);
its.AddLayer((char*)"ddd8", 55. , x0OB, xrhoOB, resRPhiOB, resZOB,eff);
// its.AddLayer((char*)"dddZ", 90. , x0OB, xrhoOB, resRPhiOB, resZOB,eff);
its.AddLayer((char*)"dddY", 80.0 , x0OB, xrhoOB, resRPhiOB, resZOB,eff);
its.AddLayer((char*)"dddX", 100.0 , x0OB, xrhoOB, resRPhiOB, resZOB,eff);
its.SetAtLeastHits(4);
its.SetAtLeastCorr(4);
its.SetAtLeastFake(0);
//
its.SetAvgRapidity(0.5);
its.SetParticleMass(mass);
its.SetMinRadTrack(55);//100.);
//
its.PrintLayout();
its.SolveViaBilloir(0.2, ptmin);
its.MakeStandardPlots(0,2,1, "grsav.root");
// return;
// its.AddTPC(0.1,0.1);
// its.AddTRD(0.02,2.5);
//its.SolveViaBilloir(0);
// its.MakeStandardPlots(1,1,1);
// its.PrintLayout(1);
}
void testDetectorCurr() {
DetectorK its("ALICE","ITS");
its.MakeAliceCurrent(0,0);
its.SetAtLeastCorr(4);
its.SetAtLeastFake(1);
its.PrintLayout();
its.SolveViaBilloir(0);
its.MakeStandardPlots(0,2,1,kTRUE);
// return;
its.AddTPC(0.1,0.1);
its.SolveViaBilloir(0);
its.MakeStandardPlots(1,1,1,kTRUE);
}
void particleDependendResolution() {
// particle dependency on resolution
// .L Detector.cxx++
Detector its("ALICE","ITS");
its.MakeAliceCurrent();
its.PrintLayout();
its.PlotLayout();
its.SolveViaBilloir(0);
its.SetRadius("bpipe",2.1);
its.AddLayer("spd0",2.2,0.001,0.0012,0.0012);
TCanvas *c1 = new TCanvas("c1","c1");
c1->Divide(2,1);
c1->cd(1); gPad->SetGridx(); gPad->SetGridy();
gPad->SetLogx(); //gPad->SetLogy();
c1->cd(2); gPad->SetGridx(); gPad->SetGridy();
gPad->SetLogx(); //gPad->SetLogy();
// compare to telescope equation ?
// c1->cd(1); its.GetGraphPointingResolutionTeleEqu(0,1)->Draw("AC");
// c1->cd(2); its.GetGraphPointingResolutionTeleEqu(1,1)->Draw("AC");
its.SetParticleMass(0.140); // pion
its.SolveViaBilloir(0,0);
c1->cd(1); its.GetGraphPointingResolution(0,1)->Draw("AC");
c1->cd(2); its.GetGraphPointingResolution(1,1)->Draw("AC");
its.SetParticleMass(0.498); // kaon
its.SolveViaBilloir(0,0);
c1->cd(1); its.GetGraphPointingResolution(0,2)->Draw("C");
c1->cd(2); its.GetGraphPointingResolution(1,2)->Draw("C");
its.SetParticleMass(0.00051); // electron
its.SolveViaBilloir(0,0);
c1->cd(1); its.GetGraphPointingResolution(0,3)->Draw("C");
c1->cd(2); its.GetGraphPointingResolution(1,3)->Draw("C");
its.SetParticleMass(0.938); // proton
its.SolveViaBilloir(0,0);
c1->cd(1); its.GetGraphPointingResolution(0,4)->Draw("C");
c1->cd(2); its.GetGraphPointingResolution(1,4)->Draw("C");
}