Geant4  10.02.p03
egs.C File Reference

Go to the source code of this file.

Functions

TFile f1 ("./Ta_1000keV_opt3.root")
 TFile f1("./Al_1033keV_opt3.root");. More...
 
h1 SetTitle ("Depth dose distribution of 1000 keV e- in Ta")
 
h1 GetXaxis () -> SetTitle("Edep (Mev.cm2/g) along x/r0 x/r0")
 
h1 GetYaxis () -> SetTitle("MeV*cm2/g")
 
h1 SetStats (kFALSE)
 
h1 SetLineColor (kBlack)
 
h1 Draw ("HIST")
 
in open ("./EGSnrc/Ta_1000keV_EGSnrc.ascii")
 in.open("./EGSnrc/Al_1033keV_EGSnrc.ascii"); More...
 
 for (int i=0 ;i< nbdata ;i++)
 
in close ()
 
legend AddEntry (h1,"ref10 ","l")
 
legend AddEntry (pt,"EGSnrc","P")
 
legend Draw ()
 

Variables

TH1D * h1 = (TH1D*) f1.Get("8")
 
ifstream in
 
TMarker * pt
 
Double_t x
 
Double_t y
 
int nbdata = 0
 
TLegend * legend = new TLegend(0.6,0.5,0.8,0.70)
 

Function Documentation

◆ AddEntry() [1/2]

legend AddEntry ( h1  ,
"ref10 "  ,
"l"   
)

◆ AddEntry() [2/2]

legend AddEntry ( pt  ,
"EGSnrc"  ,
"P"   
)

◆ close()

in close ( )

◆ Draw() [1/2]

h1 Draw ( "HIST"  )

◆ Draw() [2/2]

legend Draw ( )

◆ f1()

TFile f1 ( "./Ta_1000keV_opt3.root"  )

TFile f1("./Al_1033keV_opt3.root");.

◆ for()

for ( )

Definition at line 30 of file egs.C.

30  {
31  in >> x >> y ;
32  if (!in.good()) break;
33  pt = new TMarker(x,y,22); // 22 for triangle TMatker
34  pt->SetMarkerColor(kRed);
35  pt->Draw();
36  }
Double_t y
Definition: egs.C:26
TMarker * pt
Definition: egs.C:25
Double_t x
Definition: egs.C:26
ifstream in
Definition: egs.C:21

◆ GetXaxis()

h1 GetXaxis ( ) -> SetTitle("Edep (Mev.cm2/g) along x/r0 x/r0")

◆ GetYaxis()

h1 GetYaxis ( ) -> SetTitle("MeV*cm2/g")

◆ open()

in open ( "./EGSnrc/Ta_1000keV_EGSnrc.ascii"  )

in.open("./EGSnrc/Al_1033keV_EGSnrc.ascii");

◆ SetLineColor()

h1 SetLineColor ( kBlack  )

◆ SetStats()

h3 SetStats ( kFALSE  )
Here is the caller graph for this function:

◆ SetTitle()

h1 SetTitle ( "Depth dose distribution of 1000 keV e- in Ta"  )

Variable Documentation

◆ h1

TH1D* h1 = (TH1D*) f1.Get("8")

Definition at line 9 of file egs.C.

◆ in

ifstream in

Definition at line 21 of file egs.C.

◆ legend

TLegend* legend = new TLegend(0.6,0.5,0.8,0.70)

Definition at line 40 of file egs.C.

◆ nbdata

in nbdata = 0

Definition at line 28 of file egs.C.

◆ pt

TMarker* pt

Definition at line 25 of file egs.C.

◆ x

Double_t x

Definition at line 26 of file egs.C.

◆ y

Double_t y

Definition at line 26 of file egs.C.