File indexing completed on 2025-08-06 08:14:07
0001 #include "TROOT.h"
0002 #include "TF1.h"
0003 #include "TH1.h"
0004 #include "TH2.h"
0005 #include "TNtuple.h"
0006 #include "TFile.h"
0007 #include "TRandom.h"
0008 #include "TMath.h"
0009 #include "TGraph.h"
0010 #include "TCanvas.h"
0011 #include "TLatex.h"
0012 #include "TBox.h"
0013 #include "TGraphErrors.h"
0014 #include "TStyle.h"
0015 #include "TPolyLine.h"
0016 #include "TLegend.h"
0017
0018
0019
0020 #include <iostream>
0021 #include <fstream>
0022
0023 void nlo_plot () {
0024
0025 gROOT->Reset();
0026 gROOT->SetStyle("Plain");
0027 gStyle->SetOptTitle(0);
0028 gStyle->SetOptStat(0);
0029
0030 TCanvas *c1 = new TCanvas("c1","c1",10,10,700,900);
0031 c1->SetLogy(1);
0032
0033
0034 TH1F *h1 = new TH1F("h1","h1",100,0.0,100.0);
0035 h1->SetMaximum(1.e-2);
0036 h1->SetMinimum(1.e-21);
0037 h1->SetYTitle("Counts/Event with p_{T} > p_{T}(cut) [p-p @ 200 GeV]");
0038 h1->SetYTitle("Counts/Event [p-p @ 200 GeV]");
0039 h1->GetYaxis()->SetTitleOffset(1.5);
0040 h1->SetXTitle("Transverse Momentum (GeV/c)");
0041 h1->Draw();
0042
0043
0044
0045
0046
0047 double scalefactor = 28.0 * (2.0*3.14159*2.5*2.0) / 1.e12;
0048
0049 ifstream myfile;
0050 TGraph *tjet = new TGraph();
0051
0052 myfile.open("jets_newphenix_sc1.dat");
0053 for (int index=0; index<38; index++) {
0054 double pt; double yield;
0055 myfile >> pt >> yield;
0056 yield = yield * scalefactor*pt;
0057 tjet->SetPoint(index,pt,yield);
0058 }
0059 myfile.close();
0060 tjet->SetMarkerStyle(21);
0061 tjet->SetMarkerColor(2);
0062 tjet->SetLineColor(2);
0063 tjet->Draw("p,l,same");
0064
0065
0066
0067
0068
0069
0070
0071
0072
0073
0074
0075
0076
0077
0078
0079
0080
0081
0082
0083
0084
0085
0086
0087
0088
0089
0090
0091
0092
0093 TLegend *tleg = new TLegend(0.5,0.7,0.9,0.9,"Hard Processes pQCD @ 200 GeV","brNDC");
0094 tleg->AddEntry(tjet,"NLO pQCD W. Vogelsang","");
0095 tleg->AddEntry(tjet,"Light q + g jets","p,l");
0096 tleg->Draw("same");
0097 }