3 gStyle->SetOptTitle(0);
5 gStyle->SetPadBorderMode(0);
6 gStyle->SetFrameBorderMode(0);
12 const char * percent=
"\%";
21 const int Iterations = 1000000;
22 const int Counter = Iterations/100;
31 TH1F * hD =
new TH1F(
"hD" ,
"Fermi Momentum Distribution inside D" ,1000,0.,1.);
32 TH1F * h3He =
new TH1F(
"h3He" ,
"Fermi Momentum Distribution inside 3He" ,1000,0.,1.);
33 TH1F * h4He =
new TH1F(
"h4He" ,
"Fermi Momentum Distribution inside 4He" ,1000,0.,1.);
34 TH1F * h7Li =
new TH1F(
"h7Li" ,
"Fermi Momentum Distribution inside 7Li" ,1000,0.,1.);
35 TH1F * h12C =
new TH1F(
"h12C" ,
"Fermi Momentum Distribution inside 12C" ,1000,0.,1.);
36 TH1F * h40Ca =
new TH1F(
"h40Ca",
"Fermi Momentum Distribution inside 40Ca",1000,0.,1.);
38 TCanvas *
c1 =
new TCanvas(
"c1",
"Fermi Distribution inside different Nuclei",200,10,600,400);
40 TLegend *l1 =
new TLegend(0.7,0.6,0.89,0.89);
42 l1->AddEntry(hD,
"D",
"l");
43 l1->AddEntry(h3He,
"3He",
"l");
44 l1->AddEntry(h4He,
"4He",
"l");
45 l1->AddEntry(h7Li,
"7Li",
"l");
46 l1->AddEntry(h12C,
"12C",
"l");
47 l1->AddEntry(h40Ca,
"40Ca",
"l");
72 for (
int i=0; i<Iterations; i++)
76 printf(
" %i%s of helium-3 done in %f sec\n",cpc2-1,percent,timer.RealTime()-t0);
80 h3He ->Fill(f3He ->GetRandomFermiMomentum(px2,py2,pz2));
86 for (
int i=0; i<Iterations; i++)
90 printf(
" %i%s of helium-4 done in %f sec\n",cpc3-1,percent,timer.RealTime()-t0);
94 h4He ->Fill(f4He ->GetRandomFermiMomentum(px3,py3,pz3));
101 for (
int i=0; i<Iterations; i++)
105 printf(
" %i%s of lithium-7 done in %f sec\n",cpc4-1,percent,timer.RealTime()-t0);
109 h7Li ->Fill(f7Li ->GetRandomFermiMomentum(px4,py4,pz4));
116 for (
int i=0; i<Iterations; i++)
120 printf(
" %i%s of carbon-12 done in %f sec\n",cpc5-1,percent,timer.RealTime()-t0);
131 for (
int i=0; i<Iterations; i++)
135 printf(
" %i%s of calcium-40 done in %f sec\n",cpc6-1,percent,timer.RealTime()-t0);
144 h3He->Scale(1./h3He->GetMaximum());
145 h4He->Scale(1./h4He->GetMaximum());
146 h7Li->Scale(1./h7Li->GetMaximum());
147 h12C->Scale(1./h12C->GetMaximum());
148 h40Ca->Scale(1./h40Ca->GetMaximum());
152 hD ->SetLineColor(1);
153 hD ->SetLineWidth(2);
154 h3He ->SetLineColor(2);
155 h3He ->SetLineWidth(2);
156 h4He ->SetLineColor(3);
157 h4He ->SetLineWidth(2);
158 h7Li ->SetLineColor(4);
159 h7Li ->SetLineWidth(2);
160 h12C ->SetLineColor(5);
161 h12C ->SetLineWidth(2);
162 h40Ca->SetLineColor(6);
163 h40Ca->SetLineWidth(2);
166 hD->SetStats(kFALSE);
167 hD->SetLabelSize(.04,
"X");
168 hD->SetLabelSize(.04,
"Y");
169 hD->SetTitleSize(.04,
"X");
170 hD->SetTitleSize(.04,
"Y");
171 hD->SetLabelFont(41,
"X");
172 hD->SetLabelFont(41,
"Y");
173 hD->SetNdivisions(505,
"X");
174 hD->SetNdivisions(505,
"Y");
175 hD->GetXaxis()->CenterTitle(kTRUE);
176 hD->SetXTitle(
"#font[41]{ Fermi Momentum p_{f} [GeV]}");
177 hD->GetYaxis()->CenterTitle(kTRUE);
178 hD->SetYTitle(
"#font[41]{Counts [a.u.]}");
179 hD->SetTitleOffset(1.3,
"X");
180 hD->SetTitleOffset(1.,
"Y");