-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathplot_LQGENEP_tauOnly.C
137 lines (99 loc) · 3.54 KB
/
plot_LQGENEP_tauOnly.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
#include "TFile.h"
#include "TCanvas.h"
#include "TH2D.h"
#include "TTree.h"
#include "TMath.h"
#include "TStyle.h"
using namespace std;
int plot_LQGENEP_tauOnly()
{
gStyle->SetOptStat(0);
std::string inputFile = "./outdir/LQGENEP_20_250_q1_q1_1936-5_1000000.root";
// std::string inputFile = "./outdir/LQGENEP_30_50_q1_q1_1936-5_1000000.root";
// std::string inputFile = "./outdir/LQGENEP_5_275_q1_q1_1936-5_1000000.root";
// std::string inputFile = "./outdir/TestOut.100000event.root";
TFile *f = TFile::Open(inputFile.c_str());
TTree *t = (TTree*)f->Get("EICTree");
int vsize = t->Draw("particles.eta:particles.phi:particles.pt:particles.p","(particles.id==15)*(particles.orig==8)","goff");
double xmin = -2.5;
double xmax = 7.5;
double ymin = -0.1;
double ymax = 2*TMath::Pi()+0.1;
//-----------------------------------------------------------------------------------------------------------
std::string title = "";
// std::string title = "#eta vs. #phi for #tau^{-} produced in LQ Events";
// TCanvas *c1 = new TCanvas("c1","canvas",1000,750);
TCanvas *c1 = new TCanvas();
TH2D *h1 = new TH2D("h1",title.c_str(),50,xmin,xmax,60,ymin,ymax);
for(int i = 0; i < vsize; i++)
{
h1->Fill(t->GetV1()[i],t->GetV2()[i]);
}
h1->Draw("colz");
h1->SetMinimum(0);
h1->SetMaximum(3600);
h1->GetXaxis()->SetTitle("#eta");
h1->GetYaxis()->SetTitle("#phi");
h1->GetYaxis()->SetTitleOffset(1.4);
c1->Update();
//-----------------------------------------------------------------------------------------------------------
TCanvas *c2 = new TCanvas();
std::string title2 = "";
// std::string title2 = "#eta vs. p_{T} for #tau^{-} produced in LQ Events";
TH2D *h2 = new TH2D("h2",title2.c_str(),50,xmin,xmax,75,0,75);
for(int i = 0; i < vsize; i++)
{
h2->Fill(t->GetV1()[i],t->GetV3()[i]);
}
h2->Draw("colz");
h2->SetMinimum(0);
// h2->SetMaximum(14500);
h2->GetXaxis()->SetTitle("#eta");
h2->GetYaxis()->SetTitle("Transverse Momentum (GeV)");
c2->Update();
//-----------------------------------------------------------------------------------------------------------
TCanvas *c4 = new TCanvas();
// std::string title4 = "p_{T} vs. #Sigma p for #tau^{-} produced in LQ Events";
std::string title4 = "";
TH2D *h4 = new TH2D("h4",title4.c_str(),44,0,66,44,0,66);
for(int i = 0; i < vsize; i++)
{
h4->Fill(t->GetV3()[i],t->GetV4()[i]);
}
h4->Draw("colz");
h4->SetMinimum(0);
// h4->SetMaximum(22000);
h4->GetXaxis()->SetTitle("Transverse Momentum (GeV)");
h4->GetYaxis()->SetTitle("Total Momentum (GeV)");
c4->Update();
//-----------------------------------------------------------------------------------------------------------
std::string title5 = "";
// std::string title5 = "#eta vs. #phi for #tau^{-} produced in LQ Events";
TCanvas *c5 = new TCanvas();
TH2D *h5 = new TH2D("h5",title5.c_str(),50,xmin,xmax,75,0,250);
for(int i = 0; i < vsize; i++)
{
h5->Fill(t->GetV1()[i],t->GetV4()[i]);
}
h5->Draw("colz");
// h5->SetMinimum(0);
h5->SetMaximum(63000);
h5->GetXaxis()->SetTitle("#eta");
h5->GetYaxis()->SetTitle("p_{total} (GeV)");
h5->GetYaxis()->SetTitleOffset(1.4);
c5->SetLogz();
c5->Update();
//-----------------------------------------------------------------------------------------------------------
/*
TCanvas *c3 = new TCanvas();
c3->SetGridx();
c3->SetGridy();
// gPad->DrawFrame(-11.2,-11.2,11.2,11.2);
TPad *p = (TPad*)c3->cd();
p->SetTheta(90.);
p->SetPhi(0.);
t->Draw("11:2*TMath::ATan( TMath::E()**(-1*particles.eta))","particles.id==15"," lego2 pol");
c3->Update();
*/
return 0;
}