Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
IPNL_GAMMA
gammaware
Commits
5eb9568e
Commit
5eb9568e
authored
Apr 14, 2019
by
Antoine Lemasson
Browse files
Add LifeTime in the gamma search
Put Cubix in a TRint instead of TApplicataion to get access to the prompt
parent
2112d8ba
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
48 additions
and
8 deletions
+48
-8
src/root/gui/cubix/src/CXFileList.cpp
src/root/gui/cubix/src/CXFileList.cpp
+4
-2
src/root/gui/cubix/src/CXGammaSearch.cpp
src/root/gui/cubix/src/CXGammaSearch.cpp
+42
-4
src/root/gui/cubix/src/CXMainWindow.cpp
src/root/gui/cubix/src/CXMainWindow.cpp
+2
-2
No files found.
src/root/gui/cubix/src/CXFileList.cpp
View file @
5eb9568e
...
...
@@ -305,9 +305,11 @@ void CXFileList::DisplayObject(const TString& fname,const TString& name)
else
if
(
o
->
InheritsFrom
(
TGraph
::
Class_Name
()))
o
->
Draw
(
"PL"
);
}
}
canvas_out
->
ls
();
gPad
->
Modified
();
gPad
->
Update
();
gPad
->
GetFrame
()
->
SetBit
(
TObject
::
kCannotPick
);
}
fMainWindow
->
RefreshPad
();
}
...
...
src/root/gui/cubix/src/CXGammaSearch.cpp
View file @
5eb9568e
...
...
@@ -15,7 +15,9 @@
#include "TGLabel.h"
#include "TGButton.h"
#include "TList.h"
#include "TGResourcePool.h"
#include "GwConfig.h"
#include "LevelScheme.h"
#include "GammaLink.h"
...
...
@@ -282,17 +284,34 @@ void CXGammaSearch::FindGammaRays(Bool_t Bash)
Float_t
ELevF
=
NucLevF
->
GetEnergy
().
GetValue
();
TString
spinF
=
GetSpinFromLev
(
NucLevF
);
Float_t
LifeTime
=
NucLevI
->
GetT
().
GetValue
();
TString
LifeTimeText
=
""
;
if
(
LifeTime
!=
0
)
{
if
(
LifeTime
<
1e-12
)
LifeTimeText
=
Form
(
" ; T1/2 = %.1f fs"
,
LifeTime
*
1e15
);
if
(
LifeTime
>
1e-12
&&
LifeTime
<
1e-9
)
LifeTimeText
=
Form
(
" ; T1/2 = %.1f ps"
,
LifeTime
*
1e12
);
if
(
LifeTime
>
1e-9
&&
LifeTime
<
1e-6
)
LifeTimeText
=
Form
(
" ; T1/2 = %.1f ns"
,
LifeTime
*
1e9
);
if
(
LifeTime
>
1e-6
&&
LifeTime
<
1e-3
)
LifeTimeText
=
Form
(
" ; T1/2 = %.1f us"
,
LifeTime
*
1e6
);
if
(
LifeTime
>
1e-3
&&
LifeTime
<
1e-0
)
LifeTimeText
=
Form
(
" ; T1/2 = %.1f ms"
,
LifeTime
*
1e3
);
if
(
LifeTime
>
1e-0
)
LifeTimeText
=
Form
(
" ; T1/2 = %.1f s"
,
LifeTime
);
}
agammatrans
.
NucName
=
Nuc
.
GetSymbol
();
agammatrans
.
EGamma
=
Energy
;
agammatrans
.
EI
=
ELevI
;
agammatrans
.
EF
=
ELevF
;
agammatrans
.
SpinI
=
spinI
;
agammatrans
.
SpinF
=
spinF
;
agammatrans
.
LifeTime
=
LifeTimeText
;
avect
.
push_back
(
agammatrans
);
TString
GammaTitle
=
Form
(
" => %6.1f keV : %5s (%6.1f keV) --> %5s (%6.1f keV)"
,
Energy
,
spinI
.
Data
(),
ELevI
,
spinF
.
Data
(),
ELevF
);
// cout<<GammaTitle<<endl;
TString
GammaTitle
=
Form
(
" => %6.1f keV : %5s (%6.1f keV) --> %5s (%6.1f keV)%s"
,
Energy
,
spinI
.
Data
(),
ELevI
,
spinF
.
Data
(),
ELevF
,
LifeTimeText
.
Data
());
if
(
!
Bash
)
PrintInListBox
(
GammaTitle
.
Data
(),
kPrint
);
}
...
...
@@ -371,7 +390,7 @@ void CXGammaSearch::FindInDoubleCoincidence(Bool_t Bash)
if
(
GT
.
EGamma
==
Mat_E
[
ig
][
0
])
{
Flag
[
ig
]
=
Mat_E
[
ig
][
0
];
TransitionName
[
ig
]
=
Form
(
" %6.1f keV : %5s (%6.1f keV) --> %5s (%6.1f keV) "
,
GT
.
EGamma
,
GT
.
SpinI
.
Data
(),
GT
.
EI
,
GT
.
SpinF
.
Data
(),
GT
.
EF
);
TransitionName
[
ig
]
=
Form
(
" %6.1f keV : %5s (%6.1f keV) --> %5s (%6.1f keV)
%s
"
,
GT
.
EGamma
,
GT
.
SpinI
.
Data
(),
GT
.
EI
,
GT
.
SpinF
.
Data
(),
GT
.
EF
,
GT
.
LifeTime
.
Data
()
);
ETrans
[
ig
]
=
GT
.
EGamma
;
EI
[
ig
]
=
GT
.
EI
;
EF
[
ig
]
=
GT
.
EF
;
...
...
@@ -517,7 +536,7 @@ void CXGammaSearch::FindInTripleCoincidence()
if
(
GT
.
EGamma
==
Mat_E
[
ig
][
0
])
{
Flag
[
ig
]
=
Mat_E
[
ig
][
0
];
TransitionName
[
ig
]
=
Form
(
" %6.1f keV : %5s (%6.1f keV) --> %5s (%6.1f keV) "
,
GT
.
EGamma
,
GT
.
SpinI
.
Data
(),
GT
.
EI
,
GT
.
SpinF
.
Data
(),
GT
.
EF
);
TransitionName
[
ig
]
=
Form
(
" %6.1f keV : %5s (%6.1f keV) --> %5s (%6.1f keV)
%s
"
,
GT
.
EGamma
,
GT
.
SpinI
.
Data
(),
GT
.
EI
,
GT
.
SpinF
.
Data
(),
GT
.
EF
,
GT
.
LifeTime
.
Data
()
);
ETrans
[
ig
]
=
GT
.
EGamma
;
EI
[
ig
]
=
GT
.
EI
;
EF
[
ig
]
=
GT
.
EF
;
...
...
@@ -655,7 +674,26 @@ std::vector<int> CXGammaSearch::Sort_Index(std::vector<int> Index_Nuclei, std::v
void
CXGammaSearch
::
PrintInListBox
(
TString
mess
,
Int_t
Type
)
{
#if (OS_TYPE == OS_LINUX)
const
TGFont
*
ufont
;
// will reflect user font changes
ufont
=
gClient
->
GetFont
(
"-adobe-courier-medium-r-*-*-14-*-*-*-*-*-iso8859-1"
);
// ufont = gClient->GetFont("-adobe-times-medium-r-*-*-12-*-*-*-*-*-iso8859-1");
if
(
!
ufont
)
ufont
=
fClient
->
GetResourcePool
()
->
GetDefaultFont
();
TGGC
*
uGC
;
// will reflect user GC changes
// graphics context changes
GCValues_t
val
;
val
.
fMask
=
kGCFont
;
val
.
fFont
=
ufont
->
GetFontHandle
();
uGC
=
gClient
->
GetGC
(
&
val
,
kTRUE
);
TGTextLBEntry
*
entry
=
new
TGTextLBEntry
(
fResultsBox
->
GetContainer
(),
new
TGString
(
mess
),
fResultsBox
->
GetNumberOfEntries
()
+
1
,
uGC
->
GetGC
(),
ufont
->
GetFontStruct
());
#else
TGTextLBEntry
*
entry
=
new
TGTextLBEntry
(
fResultsBox
->
GetContainer
(),
new
TGString
(
mess
),
fResultsBox
->
GetNumberOfEntries
()
+
1
);
#endif
if
(
Type
==
kError
)
entry
->
SetBackgroundColor
((
Pixel_t
)
0xff0000
);
else
if
(
Type
==
kInfo
)
...
...
src/root/gui/cubix/src/CXMainWindow.cpp
View file @
5eb9568e
...
...
@@ -685,7 +685,7 @@ TH1 *CXMainWindow::GetHisto(TVirtualPad *pad)
void
CXMainWindow
::
UpdateContextMenus
()
{
/// TH1 ///
/// TH1
F
///
TClass
*
cl
=
gROOT
->
GetClass
(
"TH1F"
);
cl
->
MakeCustomMenuList
();
TList
*
ml
=
cl
->
GetMenuList
();
...
...
@@ -724,7 +724,7 @@ void CXMainWindow::UpdateContextMenus()
n
=
new
TClassMenuItem
(
TClassMenuItem
::
kPopupUserFunction
,
cl
,
"Scale"
,
"HistScale"
,
this
,
"Float_t,TObject*"
,
1
);
ml
->
AddAt
(
n
,
5
);
/// TH1
///
/// TH1
D
///
cl
=
gROOT
->
GetClass
(
"TH1D"
);
cl
->
MakeCustomMenuList
();
ml
=
cl
->
GetMenuList
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment