Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
nptool
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Admin message
Gitlab has been updated. More info
here
.
Show more breadcrumbs
np
nptool
Commits
f1beae6e
Commit
f1beae6e
authored
3 years ago
by
Adrien Matta
Browse files
Options
Downloads
Patches
Plain Diff
* adding betaz macro to s034
parent
017cd118
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
NPLib/Detectors/Samurai/SamuraiFieldMap.cxx
+1
-0
1 addition, 0 deletions
NPLib/Detectors/Samurai/SamuraiFieldMap.cxx
Projects/S034/macro/betaz.cxx
+49
-0
49 additions, 0 deletions
Projects/S034/macro/betaz.cxx
with
50 additions
and
0 deletions
NPLib/Detectors/Samurai/SamuraiFieldMap.cxx
+
1
−
0
View file @
f1beae6e
...
@@ -93,6 +93,7 @@ TGraph* SamuraiFieldMap::BrhoScan(double min, double max,double step){
...
@@ -93,6 +93,7 @@ TGraph* SamuraiFieldMap::BrhoScan(double min, double max,double step){
pos
.
back
().
RotateY
(
-
m_fdc2angle
);
pos
.
back
().
RotateY
(
-
m_fdc2angle
);
m_BrhoScan
->
SetPoint
(
i
++
,
pos
.
back
().
X
(),
b
);
m_BrhoScan
->
SetPoint
(
i
++
,
pos
.
back
().
X
(),
b
);
}
}
m_BrhoScan
->
Sort
();
return
m_BrhoScan
;
return
m_BrhoScan
;
}
}
...
...
This diff is collapsed.
Click to expand it.
Projects/S034/macro/betaz.cxx
0 → 100644
+
49
−
0
View file @
f1beae6e
void
betaz
(){
auto
fz
=
new
TFile
(
"root/zaihong/run0582_RIG20210424_6He.root"
);
auto
tz
=
(
TTree
*
)
fz
->
FindObjectAny
(
"rig"
);
auto
fl
=
new
TFile
(
"root/analysis/Result582.root"
);
auto
tl
=
(
TTree
*
)
fl
->
FindObjectAny
(
"PhysicsTree"
);
tl
->
AddFriend
(
tz
);
double
Brho
,
betaZ
,
beta
;
int
FragID
;
tl
->
SetBranchAddress
(
"Brho"
,
&
Brho
);
tl
->
SetBranchAddress
(
"fBeta"
,
&
betaZ
);
tl
->
SetBranchAddress
(
"FragID"
,
&
FragID
);
NPL
::
Particle
H2
(
"2H"
);
NPL
::
Particle
H3
(
"3H"
);
NPL
::
Particle
He4
(
"4He"
);
NPL
::
Particle
He6
(
"6He"
);
auto
z
=
new
TH1D
(
"betaZ"
,
"betaZ"
,
100
,
0.45
,
0.6
);
auto
b
=
new
TH1D
(
"betaF"
,
"betaZ"
,
100
,
0.45
,
0.6
);
auto
d
=
new
TH1D
(
"betaF"
,
"betaZ"
,
1000
,
-
0.01
,
0.01
);
unsigned
int
entries
=
tl
->
GetEntries
();
for
(
unsigned
int
i
=
0
;
i
<
entries
;
i
++
){
tl
->
GetEntry
(
i
);
if
(
FragID
>
0
&&
FragID
<
27
){
// compute Brho based on beta and FragID
double
rig
;
if
(
FragID
==
26
){
He6
.
SetBrho
(
Brho
);
beta
=
He6
.
GetBeta
();
b
->
Fill
(
beta
);
z
->
Fill
(
betaZ
);
d
->
Fill
(
beta
-
betaZ
);
}
}
}
// h->Scale(1./h->Integral());
// h->Draw(); h->SetLineColor(kBlack);
b
->
Draw
(
""
);
b
->
Scale
(
1.
/
b
->
Integral
());
b
->
SetLineColor
(
kAzure
+
7
);
b
->
SetLineWidth
(
2
);
z
->
Scale
(
1.
/
z
->
Integral
());
z
->
SetLineColor
(
kOrange
+
7
);
z
->
SetLineWidth
(
2
);
z
->
Draw
(
"same"
);
new
TCanvas
();
d
->
Draw
();
d
->
SetLineColor
(
kAzure
+
7
);
b
->
SetLineWidth
(
2
);
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment