36 void gasTemp_2d_pos(
int ftpc,
int lsec,
float deltaT, TString a,
char *opt)
43 const Float_t lpos1=11.88;
44 const Float_t lpos2=19.55;
45 const Float_t lpos3=28.56;
46 TH2F *hr1 =
new TH2F(
"hr1",
"Laser I(west,lsec 1): nominal (11.88cm) - reconstructed position",12,deltaT-2.00,deltaT+4.00,12,-0.45,0.75);
47 TH2F *hr2 =
new TH2F(
"hr2",
"Laser II(west,lsec 1): nominal (19.55cm) - reconstructed position",12,deltaT-2.00,deltaT+4.00,12,-0.45,0.75);
48 TH2F *hr3 =
new TH2F(
"hr3",
"Laser III(west,lsec 1): nominal (28.56cm) - reconstructed position",12,deltaT-2.00,deltaT+4.00,12,-0.45,0.75);
49 cout<<
"Initialized for ftpc = "<<ftpc<<
"(west) lsec = "<<lsec<<endl;
53 const Float_t lpos1=11.68;
54 const Float_t lpos2=19.45;
55 const Float_t lpos3=28.51;
56 TH2F *hr1 =
new TH2F(
"hr1",
"Laser I(west,lsec 2): nominal (11.68cm) - reconstructed position",12,deltaT-2.00,deltaT+4.00,12,-0.45,0.75);
57 TH2F *hr2 =
new TH2F(
"hr2",
"Laser II(west,lsec 2): nominal (19.45cm) - reconstructed position",12,deltaT-2.00,deltaT+4.00,12,-0.45,0.75);
58 TH2F *hr3 =
new TH2F(
"hr3",
"Laser III(west,lsec 2): nominal (28.51cm) - reconstructed position",12,deltaT-2.00,deltaT+4.00,12,-0.45,0.75);
59 cout<<
"Initialized for ftpc = "<<ftpc<<
"(west) lsec = "<<lsec<<endl;
63 const Float_t lpos1=11.78;
64 const Float_t lpos2=19.35;
65 const Float_t lpos3=28.41;
66 TH2F *hr1 =
new TH2F(
"hr1",
"Laser I(west,lsec 3): nominal (11.78cm) - reconstructed position",12,deltaT-2.00,deltaT+4.00,12,-0.45,0.75);
67 TH2F *hr2 =
new TH2F(
"hr2",
"Laser II(west,lsec 3): nominal (19.35cm) - reconstructed position",12,deltaT-2.00,deltaT+4.00,12,-0.45,0.75);
68 TH2F *hr3 =
new TH2F(
"hr3",
"Laser III(west,lsec 3): nominal (28.41cm) - reconstructed position",12,deltaT-2.00,deltaT+4.00,12,-0.45,0.75);
69 cout<<
"Initialized for ftpc = "<<ftpc<<
"(west) lsec = "<<lsec<<endl;
72 cout<<
"Invalid lsec for ftpc = "<<ftpc<<
"(west) lsec = "<<lsec<<endl;
81 const Float_t lpos1=11.75;
82 const Float_t lpos2=19.44;
83 const Float_t lpos3=28.41;
84 TH2F *hr1 =
new TH2F(
"hr1",
"Laser I(east,lsec 1): nominal (11.75cm) - reconstructed position",12,deltaT-2.00,deltaT+4.00,12,-0.45,0.75);
85 TH2F *hr2 =
new TH2F(
"hr2",
"Laser II(east,lsec 1): nominal (19.44cm) - reconstructed position",12,deltaT-2.00,deltaT+4.00,12,-0.45,0.75);
86 TH2F *hr3 =
new TH2F(
"hr3",
"Laser III(east,lsec 1): nominal (28.41cm) - reconstructed position",12,deltaT-2.00,deltaT+4.00,12,-0.45,0.75);
87 cout<<
"Initialized for ftpc = "<<ftpc<<
"(east) lsec = "<<lsec<<endl;
91 const Float_t lpos1=11.85;
92 const Float_t lpos2=19.44;
93 const Float_t lpos3=28.41;
94 TH2F *hr1 =
new TH2F(
"hr1",
"Laser I(east,lsec 2): nominal (11.85cm) - reconstructed position",12,deltaT-2.00,deltaT+4.00,12,-0.45,0.75);
95 TH2F *hr2 =
new TH2F(
"hr2",
"Laser II(east,lsec 2): nominal (19.44cm) - reconstructed position",12,deltaT-2.00,deltaT+4.00,12,-0.45,0.75);
96 TH2F *hr3 =
new TH2F(
"hr3",
"Laser III(east,lsec 2): nominal (28.41cm) - reconstructed position",12,deltaT-2.00,deltaT+4.00,12,-0.45,0.75);
97 cout<<
"Initialized for ftpc = "<<ftpc<<
"(east) lsec = "<<lsec<<endl;
101 const Float_t lpos1=11.86;
102 const Float_t lpos2=19.45;
103 const Float_t lpos3=28.31;
104 TH2F *hr1 =
new TH2F(
"hr1",
"Laser I(east,lsec 3): nominal (11.86cm) - reconstructed position",12,deltaT-2.00,deltaT+4.00,12,-0.45,0.75);
105 TH2F *hr2 =
new TH2F(
"hr2",
"Laser II(east,lsec 3): nominal (19.45cm) - reconstructed position",12,deltaT-2.00,deltaT+4.00,12,-0.45,0.75);
106 TH2F *hr3 =
new TH2F(
"hr3",
"Laser III(east,lsec 3): nominal (28.31cm) - reconstructed position",12,deltaT-2.00,deltaT+4.00,12,-0.45,0.75);
107 cout<<
"Initialized for ftpc = "<<ftpc<<
"(east) lsec = "<<lsec<<endl;
110 cout<<
"Invalid lsec for ftpc = "<<ftpc<<
"(east) lsec = "<<lsec<<endl;
115 TCanvas *c1 =
new TCanvas(
"c1",
"ps",200,10,700,500);
117 gStyle->SetPalette(1);
118 gStyle->SetOptStat(0);
119 gStyle->SetOptFit(0);
129 TH2F *hr0 =
new TH2F(
"hr",
"",12,deltaT-2.00,deltaT+4.00,12,-0.45,0.75);
130 hr0->GetYaxis()->SetTitle(
"#Delta Ar [%]");
131 hr0->GetXaxis()->SetTitle(
"#Delta T");
132 hr1->GetYaxis()->SetTitle(
"#Delta Ar [%]");
133 hr1->GetXaxis()->SetTitle(
"#Delta T");
134 hr2->GetYaxis()->SetTitle(
"#Delta Ar [%]");
135 hr2->GetXaxis()->SetTitle(
"#Delta T");
136 hr3->GetYaxis()->SetTitle(
"#Delta Ar [%]");
137 hr3->GetXaxis()->SetTitle(
"#Delta T");
141 sprintf(name,
"res.log",lsec);
143 printf(
"Input file opened %s \n",name);
145 FILE *file1=fopen (name,
"r");
151 float resx,resy,resrad,resphi, t0, gas, T, c2,rad1,rad11, rad2, rad21, rad3, rad31, err;
155 datab1 = fscanf(file1,
"%f %f %f %f %f",&t0,&gas,&T,&resx,&c2);
156 datab1 = fscanf(file1,
"%f %f %f %f %f",&t0,&gas,&T,&resy,&c2);
157 datab1 = fscanf(file1,
"%f %f %f %f %f",&t0,&gas,&T,&resrad,&c2);
158 datab1 = fscanf(file1,
"%f %f %f %f %f",&t0,&gas,&T,&resphi,&c2);
159 datab1 = fscanf(file1,
"%f %f %f %f %f",&t0,&gas,&T,&rad1,&err);
160 datab1 = fscanf(file1,
"%f %f %f %f",&t0,&gas,&T,&rad11);
161 datab1 = fscanf(file1,
"%f %f %f %f %f",&t0,&gas,&T,&rad2,&err);
162 datab1 = fscanf(file1,
"%f %f %f %f",&t0,&gas,&T,&rad21);
163 datab1 = fscanf(file1,
"%f %f %f %f %f",&t0,&gas,&T,&rad3,&err);
164 datab1 = fscanf(file1,
"%f %f %f %f",&t0,&gas,&T,&rad31);
165 if (feof(file1))
break;
169 hr0->Fill(T,gas,lpos1-rad1);
173 hr0->Fill(T,gas,lpos2-rad2);
177 hr0->Fill(T,gas,lpos3-rad3);
181 hr1->Fill(T,gas,lpos1-rad1);
182 hr2->Fill(T,gas,lpos2-rad2);
183 hr3->Fill(T,gas,lpos3-rad3);
186 {cout<<
"Function not available !"<<endl;
break;}
206 if(ftpc==1) sprintf(name,
"w_lsec%d_2d_Del_g-Del_T%g.ps",lsec,deltaT);
207 if(ftpc==2) sprintf(name,
"e_lsec%d_2d_Del_g-Del_T%g.ps",lsec,deltaT);
209 if(ftpc==1) sprintf(name,
"w_lsec%d_2d_Del_g-Del_T%g.png",lsec,deltaT);
210 if(ftpc==2) sprintf(name,
"e_lsec%d_2d_Del_g-Del_T%g.png",lsec,deltaT);
213 if (fclose(file1) != 0)
214 cout<<
"Error closing input file !"<<endl;