35 fX(0),fY(0),fZ(0),fVX(0),fVY(0),fVZ(0),fNumScatt(0),
36 fXY(0),fVXVY(0), fXYCond(0), fVXVYCond(0), fEmitX(0), fEmitY(0), fEmitDist(0),
37 fWinConR(0), fWinConV(0), fPolyConEmit(0),
44 fX(0),fY(0),fZ(0),fVX(0),fVY(0),fVZ(0),fNumScatt(0),
45 fXY(0),fVXVY(0), fXYCond(0), fVXVYCond(0), fEmitX(0), fEmitY(0), fEmitDist(0),
46 fWinConR(0), fWinConV(0), fPolyConEmit(0),
56 fX =
MakeTH1(
'D',
"Position/Xfinal",
"Scatt sim x (nm)",1000,-1e7,1e+7);
57 fY =
MakeTH1(
'D',
"Position/Yfinal",
"Scatt sim y (nm)",1000,-1e7,1e+7);
58 fZ =
MakeTH1(
'D',
"Position/Zfinal",
"Scatt sim z (nm)",1000, 1., 1e+8);
60 fVX =
MakeTH1(
'D',
"Velocity/Vxfinal",
"Scatt sim vx (nm/ps)",10000, -5e+3,5e+3);
61 fVY =
MakeTH1(
'D',
"Velocity/Vyfinal",
"Scatt sim vy (nm/ps)",10000, -5e+3,5e+3);
62 fVZ =
MakeTH1(
'D',
"Velocity/Vzfinal",
"Scatt sim vz (nm/ps)",10000, 1.,3e+4);
63 fThetaX=
MakeTH1(
'D',
"Angle/thetax",
"Scatt sim x' (mrad)",10000, -5e+2,5e+2);
64 fThetaY=
MakeTH1(
'D',
"Angle/thetay",
"Scatt sim y' (mrad)",10000, -5e+2,5e+2);
65 fThetaR=
MakeTH1(
'D',
"Angle/thetaR",
"Scatt sim r' (mrad)",10000, 0,2e+3);
66 fNumScatt =
MakeTH1(
'D',
"Nscatt",
"Multiple scattering collisions",50000, 0, 50000.);
68 fXY =
MakeTH2(
'D',
"Position/X-Y",
"x versus y final",100,-1e7,1e+7,100,-1e+7,1e+7);
69 fVXVY =
MakeTH2(
'D',
"Velocity/Vx-Vy",
"vx versus vy final",1000,-5e+3,5e+3,1000,-5e+3,5e+3);
70 fXYCond =
MakeTH2(
'D',
"Position/X-Y-cond",
"x versus y final",1000,-1e+7,1e+7,1000,-1e+7,1e+7);
71 fVXVYCond =
MakeTH2(
'D',
"Velocity/Vx-Vy-cond",
"vx versus vy final",100,-1e+3,1e+3,100,-1e+3,1e+3);
73 fEmitX =
MakeTH2(
'D',
"X-X'",
"transverse emittance x",1000,-1e+7,1e+7,1000,-0.1,0.1);
74 fEmitY =
MakeTH2(
'D',
"Y-Y'",
"transverse emittance y",1000,-1e+7,1e+7,1000,-0.1,0.1);
75 fEmitDist =
MakeTH1(
'D',
"Emit4d",
"transverse emittance distribution",4000,0,2e+5);
84 Double_t cutpnts[3][2] = { {400, 800}, {700, 900}, {600, 1100} };
91 TCanvas* mycan =
new TCanvas(
"TestCanvas2",
"Does this work2?");
111 return cl->InheritsFrom(TYYYUnpackEvent::Class());
123 if ((inp==0) || (poutevt==0)) {
129 for(Int_t i=0; i<3;++i)
134 poutevt->
fdR[0]-=5e+6;
135 poutevt->
fdR[1]-=5e+6;
138 if(poutevt->
fdV[2]) poutevt->
fdGam[0]=poutevt->
fdV[0]/poutevt->
fdV[2];
139 if(poutevt->
fdV[2]) poutevt->
fdGam[1]=poutevt->
fdV[1]/poutevt->
fdV[2];
140 Double_t scalefact=1e-3;
145 fX->Fill(poutevt->
fdR[0]);
146 fY->Fill(poutevt->
fdR[1]);
147 fZ->Fill(poutevt->
fdR[2]);;
148 fVX->Fill(poutevt->
fdV[0]);
149 fVY->Fill(poutevt->
fdV[1]);
150 fVZ->Fill(poutevt->
fdV[2]);
155 fThetaR->Fill(TMath::Sqrt(poutevt->
fdV[1]*poutevt->
fdV[1] + poutevt->
fdV[0]*poutevt->
fdV[0])/poutevt->
fdV[2] * 1000);
158 fXY->Fill(poutevt->
fdR[0],poutevt->
fdR[1]);
virtual void PrintCondition(Bool_t points=kTRUE)
TGo4PolyCond * fPolyConEmit
virtual void PrintCondition(Bool_t full=kTRUE)
TH2 * MakeTH2(char type, const char *fullname, const char *title, Int_t nbinsx, Double_t xlow, Double_t xup, Int_t nbinsy, Double_t ylow, Double_t yup, const char *xtitle=0, const char *ytitle=0, const char *ztitle=0)
virtual Int_t PrintParameter(Text_t *n, Int_t)
TGo4WinCond * MakeWinCond(const char *fullname, Double_t xmin, Double_t xmax, const char *HistoName=0)
virtual Bool_t BuildEvent(TGo4EventElement *dest)
TGo4PolyCond * MakePolyCond(const char *fullname, Int_t npoints, Double_t(*points)[2], const char *HistoName=0)
TCanvas * GetCanvas(const char *name)
Bool_t AddCanvas(TCanvas *can, const char *subfolder=0)
virtual void Disable(Bool_t result)
TGo4Parameter * GetParameter(const char *name, const char *par_class=0)
TGo4EventElement * GetInputEvent()
virtual Bool_t Test(Double_t v1)
TH1 * MakeTH1(char type, const char *fullname, const char *title, Int_t nbinsx, Double_t xlow, Double_t xup, const char *xtitle=0, const char *ytitle=0)
virtual Bool_t CheckEventClass(TClass *cl)
static void Error(const char *text,...)
static void Info(const char *text,...)
virtual void Invert(Bool_t on)
virtual ~TYYYUnpackProc()