Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
AUSA
Erik
nuchart
Commits
0162b708
Commit
0162b708
authored
Nov 20, 2020
by
Erik Asbjørn Mikkelsen Jensen
Browse files
more safety checks
parent
ce0dd3f5
Changes
2
Show whitespace changes
Inline
Side-by-side
expansion/expand-nuchart-QEC2p.cxx
View file @
0162b708
...
...
@@ -71,6 +71,9 @@ int main() {
if
(
indP
!=
-
1
&&
indD
!=
-
1
)
{
QEC2p_calc
=
1
;
QEC2p_err_calc
=
1
;
a
->
GetEntry
(
indP
);
if
(
QEC
.
QEC_calc
==
0
)
{
QEC2p_NAN
();
}
else
{
if
(
QEC
.
QEC_est
==
1
)
{
QEC2p_est
=
1
;
QEC2p_err_est
=
1
;
}
...
...
@@ -97,6 +100,7 @@ int main() {
qec2p_err
.
QEC2p_err_est
=
QEC2p_err_est
;
qec2p_err
.
QEC2p_err_calc
=
QEC2p_err_calc
;
}
}
}
else
if
(
indP
!=
-
1
)
{
QEC2p_NAN
();
}
else
{
...
...
expansion/expand-nuchart-QECp.cxx
View file @
0162b708
...
...
@@ -80,13 +80,16 @@ int main() {
if
(
indP
!=
-
1
&&
indD
!=
-
1
)
{
QECp_calc
=
1
;
QECp_err_calc
=
1
;
a
->
GetEntry
(
indP
);
if
(
QEC
.
QEC_calc
==
0
)
{
// this is new compared to 'expand-nuchart-QEC.cxx': QEC might not be defined, so we need to check for this
QECp_NAN
();
}
else
{
if
(
QEC
.
QEC_est
==
1
)
{
QECp_est
=
1
;
QECp_err_est
=
1
;
}
QECP
=
QEC
.
QEC
;
QECP_err
=
QEC_err
.
QEC_err
;
a
->
GetEntry
(
indD
);
if
(
Sp
.
Sp_calc
==
0
)
{
//
this is new compared to 'expand-nuchart-QEC.cxx': Sp might not be defined, so we need to check
for
this
if
(
Sp
.
Sp_calc
==
0
)
{
//
same goes
for
Sp
QECp_NAN
();
}
else
{
if
(
Sp
.
Sp_est
==
1
)
{
...
...
@@ -106,6 +109,7 @@ int main() {
qecp_err
.
QECp_err_est
=
QECp_err_est
;
qecp_err
.
QECp_err_calc
=
QECp_err_calc
;
}
}
}
else
if
(
indP
!=
-
1
)
{
QECp_NAN
();
}
else
{
...
...
Write
Preview
Supports
Markdown
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