Problem 1414 - simulation results with statistical uncertainty are not expressed correctly
Summary: simulation results with statistical uncertainty are not expressed correctly
Status: RESOLVED FIXED
Alias: None
Product: Examples/Basic and Novice
Classification: Unclassified
Component: N03 (show other problems)
Version: 9.6
Hardware: All All
: P5 trivial
Assignee: Michel.Maire
URL:
Depends on:
Blocks:
 
Reported: 2012-12-26 09:29 CET by Fada Guan
Modified: 2013-01-07 23:47 CET (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this problem.
Description Fada Guan 2012-12-26 09:29:28 CET
the simulation result should be expressed by:

sample mean +- S/sqrt(n),

where sample mean is sum/n, and S is square root of sample variance, and n is number of events. Here S/sqrt(n) is the standard error of the sample mean.

However, the simulation result in N03 and N03Con is expressed by:

sample mean +- S.


My suggestion is please correct some statements in the RunAction.cc

for example, rmsEAbs = std::sqrt(rmsEAbs); should be:

rmsEAbs = std::sqrt(rmsEAbs)/std::sqrt(NbOfEvents); 

other three statements, like rmsEGap should also be corrected.

For examples\extended\analysis\N03Con, it has the same problem.

Actually, the calculation in G4ConvergenceTester() is correct.
Comment 1 michel.maire 2013-01-05 11:44:05 CET
Done.
As results are printed, you are right.
However, in HEP, S is also a quantity of interest: it is related to the intrinsic resolution of the calorimeter. This was the initial motivation of the example.