How To: Compare theory predictions with experimental limits

In [1]:
# Set up the path to SModelS installation folder
import sys; sys.path.append("."); import smodels_paths
In [2]:
# Import those parts of smodels that are needed for this exercise
# (We will assume the input is a SLHA file. For LHE files, use the lheDecomposer instead)
from smodels.theory import slhaDecomposer
from smodels.installation import installDirectory
from smodels.tools.physicsUnits import fb, GeV
from smodels.theory.theoryPrediction import theoryPredictionsFor
from smodels.experiment.databaseObj import Database
In [4]:
# Define the SLHA input file name
filename="%s/inputFiles/slha/gluino_squarks.slha" % installDirectory()
In [5]:
# Load the database, do the decomposition and compute theory predictions:
# (Look at the theory predictions HowTo to learn how to compute theory predictions)
database = Database("official")
expResults = database.getExpResults()
topList = slhaDecomposer.decompose(filename, sigcut = 0.03 * fb, doCompress=True, doInvisible=True,minmassgap = 5* GeV)
allThPredictions = [theoryPredictionsFor(exp, topList) for exp in expResults]
In [6]:
# Print the value of each theory prediction for each experimental
# result and the corresponding upper limit (see the obtain experimental upper limits HowTo to learn how
# to compute the upper limits).
# lso print the expected upper limit, if available
for thPreds in allThPredictions:
    if not thPreds: continue #skip results with no predictions
    for theoryPred in thPreds:
        expID = theoryPred.expResult.globalInfo.id
        dataType = theoryPred.dataset.dataInfo.dataType
        print ( "\nExperimental Result: %s (%s-type)" %(expID,dataType) ) #Result ID and type 
        print ( "Theory prediction xsec = ",theoryPred.xsection.value )#Signal xsection*efficiency*BR
        print ( "Upper limit = ",theoryPred.expResult.getUpperLimitFor(mass = theoryPred.mass, 
                                                              txname=theoryPred.txnames[0], 
                                                              dataID = theoryPred.dataset.dataInfo.dataId) )
        print ( "Expected Upper limit = ",theoryPred.expResult.getUpperLimitFor(mass = theoryPred.mass, 
                                                              txname=theoryPred.txnames[0], 
                                                              dataID = theoryPred.dataset.dataInfo.dataId,
                                                               expected= True) )
Experimental Result: ATLAS-SUSY-2015-06 (efficiencyMap-type)
Theory prediction xsec =  2.79E-04 [pb]
Upper limit =  None
Expected Upper limit =  None

Experimental Result: CMS-PAS-SUS-16-022 (upperLimit-type)
Theory prediction xsec =  3.50E-05 [pb]
Upper limit =  1.08E+02 [fb]
Expected Upper limit =  8.84E+01 [fb]

Experimental Result: CMS-PAS-SUS-17-004 (upperLimit-type)
Theory prediction xsec =  3.99E-02 [pb]
Upper limit =  3.68E+02 [fb]
Expected Upper limit =  None

Experimental Result: CMS-PAS-SUS-17-004 (upperLimit-type)
Theory prediction xsec =  2.07E-01 [pb]
Upper limit =  1.57E+03 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-16-033 (upperLimit-type)
Theory prediction xsec =  1.15E-02 [pb]
Upper limit =  8.64E+00 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-16-033 (upperLimit-type)
Theory prediction xsec =  7.53E-03 [pb]
Upper limit =  6.79E+00 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-16-033 (upperLimit-type)
Theory prediction xsec =  3.50E-05 [pb]
Upper limit =  6.84E+00 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-16-034 (upperLimit-type)
Theory prediction xsec =  3.99E-02 [pb]
Upper limit =  1.57E+03 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-16-035 (upperLimit-type)
Theory prediction xsec =  3.50E-05 [pb]
Upper limit =  2.76E+01 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-16-036 (upperLimit-type)
Theory prediction xsec =  7.53E-03 [pb]
Upper limit =  9.30E+00 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-16-036 (upperLimit-type)
Theory prediction xsec =  3.50E-05 [pb]
Upper limit =  1.46E+01 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-16-036 (upperLimit-type)
Theory prediction xsec =  1.15E-02 [pb]
Upper limit =  7.68E+00 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-16-037 (upperLimit-type)
Theory prediction xsec =  3.50E-05 [pb]
Upper limit =  4.44E+00 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-16-039 (upperLimit-type)
Theory prediction xsec =  2.07E-01 [pb]
Upper limit =  2.12E+03 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-16-039 (upperLimit-type)
Theory prediction xsec =  3.99E-02 [pb]
Upper limit =  4.68E+02 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-16-041 (upperLimit-type)
Theory prediction xsec =  3.50E-05 [pb]
Upper limit =  2.54E+01 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-16-042 (upperLimit-type)
Theory prediction xsec =  3.50E-05 [pb]
Upper limit =  7.85E+00 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-16-043 (upperLimit-type)
Theory prediction xsec =  2.07E-01 [pb]
Upper limit =  1.27E+04 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-16-045 (upperLimit-type)
Theory prediction xsec =  2.07E-01 [pb]
Upper limit =  2.44E+03 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-16-050 (upperLimit-type)
Theory prediction xsec =  3.50E-05 [pb]
Upper limit =  5.50E+00 [fb]
Expected Upper limit =  5.35E+00 [fb]

Experimental Result: ATLAS-CONF-2013-007 (upperLimit-type)
Theory prediction xsec =  3.07E-06 [pb]
Upper limit =  2.19E+01 [fb]
Expected Upper limit =  None

Experimental Result: ATLAS-CONF-2013-024 (efficiencyMap-type)
Theory prediction xsec =  1.57E-06 [pb]
Upper limit =  None
Expected Upper limit =  None

Experimental Result: ATLAS-CONF-2013-037 (efficiencyMap-type)
Theory prediction xsec =  7.32E-07 [pb]
Upper limit =  None
Expected Upper limit =  None

Experimental Result: ATLAS-CONF-2013-047 (efficiencyMap-type)
Theory prediction xsec =  2.67E-04 [pb]
Upper limit =  None
Expected Upper limit =  None

Experimental Result: ATLAS-CONF-2013-048 (efficiencyMap-type)
Theory prediction xsec =  1.34E-07 [pb]
Upper limit =  None
Expected Upper limit =  None

Experimental Result: ATLAS-CONF-2013-053 (efficiencyMap-type)
Theory prediction xsec =  9.67E-08 [pb]
Upper limit =  None
Expected Upper limit =  None

Experimental Result: ATLAS-CONF-2013-054 (efficiencyMap-type)
Theory prediction xsec =  9.49E-06 [pb]
Upper limit =  None
Expected Upper limit =  None

Experimental Result: ATLAS-CONF-2013-061 (upperLimit-type)
Theory prediction xsec =  3.07E-06 [pb]
Upper limit =  1.07E+01 [fb]
Expected Upper limit =  None

Experimental Result: ATLAS-CONF-2013-061 (efficiencyMap-type)
Theory prediction xsec =  1.22E-06 [pb]
Upper limit =  None
Expected Upper limit =  None

Experimental Result: ATLAS-CONF-2013-062 (efficiencyMap-type)
Theory prediction xsec =  8.87E-07 [pb]
Upper limit =  None
Expected Upper limit =  None

Experimental Result: ATLAS-CONF-2013-089 (upperLimit-type)
Theory prediction xsec =  6.66E-03 [pb]
Upper limit =  4.05E+04 [fb]
Expected Upper limit =  None

Experimental Result: ATLAS-SUSY-2013-02 (upperLimit-type)
Theory prediction xsec =  1.96E-03 [pb]
Upper limit =  6.10E+00 [fb]
Expected Upper limit =  None

Experimental Result: ATLAS-SUSY-2013-02 (upperLimit-type)
Theory prediction xsec =  6.62E-04 [pb]
Upper limit =  1.08E+01 [fb]
Expected Upper limit =  None

Experimental Result: ATLAS-SUSY-2013-02 (upperLimit-type)
Theory prediction xsec =  9.07E-03 [pb]
Upper limit =  3.24E+01 [fb]
Expected Upper limit =  None

Experimental Result: ATLAS-SUSY-2013-02 (upperLimit-type)
Theory prediction xsec =  6.66E-03 [pb]
Upper limit =  1.72E+01 [fb]
Expected Upper limit =  None

Experimental Result: ATLAS-SUSY-2013-02 (efficiencyMap-type)
Theory prediction xsec =  6.23E-04 [pb]
Upper limit =  None
Expected Upper limit =  None

Experimental Result: ATLAS-SUSY-2013-04 (upperLimit-type)
Theory prediction xsec =  3.07E-06 [pb]
Upper limit =  1.09E+01 [fb]
Expected Upper limit =  None

Experimental Result: ATLAS-SUSY-2013-04 (efficiencyMap-type)
Theory prediction xsec =  1.53E-04 [pb]
Upper limit =  None
Expected Upper limit =  None

Experimental Result: ATLAS-SUSY-2013-09 (upperLimit-type)
Theory prediction xsec =  3.07E-06 [pb]
Upper limit =  1.36E+01 [fb]
Expected Upper limit =  None

Experimental Result: ATLAS-SUSY-2013-11 (upperLimit-type)
Theory prediction xsec =  1.85E-02 [pb]
Upper limit =  9.25E+02 [fb]
Expected Upper limit =  None

Experimental Result: ATLAS-SUSY-2013-11 (efficiencyMap-type)
Theory prediction xsec =  4.39E-05 [pb]
Upper limit =  None
Expected Upper limit =  None

Experimental Result: ATLAS-SUSY-2013-12 (upperLimit-type)
Theory prediction xsec =  1.85E-02 [pb]
Upper limit =  3.31E+02 [fb]
Expected Upper limit =  None

Experimental Result: ATLAS-SUSY-2013-18 (upperLimit-type)
Theory prediction xsec =  3.07E-06 [pb]
Upper limit =  3.78E+00 [fb]
Expected Upper limit =  None

Experimental Result: ATLAS-SUSY-2013-18 (efficiencyMap-type)
Theory prediction xsec =  1.32E-07 [pb]
Upper limit =  None
Expected Upper limit =  None

Experimental Result: CMS-PAS-SUS-13-016 (upperLimit-type)
Theory prediction xsec =  3.07E-06 [pb]
Upper limit =  3.04E+01 [fb]
Expected Upper limit =  None

Experimental Result: CMS-PAS-SUS-13-016 (efficiencyMap-type)
Theory prediction xsec =  2.88E-08 [pb]
Upper limit =  None
Expected Upper limit =  None

Experimental Result: CMS-SUS-12-024 (upperLimit-type)
Theory prediction xsec =  3.07E-06 [pb]
Upper limit =  2.60E+01 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-12-024 (efficiencyMap-type)
Theory prediction xsec =  3.79E-08 [pb]
Upper limit =  None
Expected Upper limit =  None

Experimental Result: CMS-SUS-12-028 (upperLimit-type)
Theory prediction xsec =  6.62E-04 [pb]
Upper limit =  3.14E+01 [fb]
Expected Upper limit =  1.92E+01 [fb]

Experimental Result: CMS-SUS-12-028 (upperLimit-type)
Theory prediction xsec =  3.07E-06 [pb]
Upper limit =  3.61E+01 [fb]
Expected Upper limit =  2.64E+01 [fb]

Experimental Result: CMS-SUS-12-028 (upperLimit-type)
Theory prediction xsec =  1.96E-03 [pb]
Upper limit =  1.64E+01 [fb]
Expected Upper limit =  9.56E+00 [fb]

Experimental Result: CMS-SUS-13-002 (upperLimit-type)
Theory prediction xsec =  3.07E-06 [pb]
Upper limit =  1.70E+01 [fb]
Expected Upper limit =  2.85E+04 [fb]

Experimental Result: CMS-SUS-13-004 (upperLimit-type)
Theory prediction xsec =  3.07E-06 [pb]
Upper limit =  1.68E+01 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-13-006 (upperLimit-type)
Theory prediction xsec =  1.85E-02 [pb]
Upper limit =  4.64E+02 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-13-006 (upperLimit-type)
Theory prediction xsec =  9.59E-02 [pb]
Upper limit =  1.14E+03 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-13-007 (upperLimit-type)
Theory prediction xsec =  3.07E-06 [pb]
Upper limit =  4.11E+00 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-13-007 (efficiencyMap-type)
Theory prediction xsec =  2.07E-08 [pb]
Upper limit =  None
Expected Upper limit =  None

Experimental Result: CMS-SUS-13-012 (upperLimit-type)
Theory prediction xsec =  6.62E-04 [pb]
Upper limit =  1.11E+01 [fb]
Expected Upper limit =  8.03E+00 [fb]

Experimental Result: CMS-SUS-13-012 (upperLimit-type)
Theory prediction xsec =  3.07E-06 [pb]
Upper limit =  1.66E+01 [fb]
Expected Upper limit =  1.12E+01 [fb]

Experimental Result: CMS-SUS-13-012 (upperLimit-type)
Theory prediction xsec =  1.96E-03 [pb]
Upper limit =  1.08E+01 [fb]
Expected Upper limit =  6.10E+00 [fb]

Experimental Result: CMS-SUS-13-012 (efficiencyMap-type)
Theory prediction xsec =  8.71E-05 [pb]
Upper limit =  None
Expected Upper limit =  None

Experimental Result: CMS-SUS-13-013 (upperLimit-type)
Theory prediction xsec =  3.07E-06 [pb]
Upper limit =  1.76E+01 [fb]
Expected Upper limit =  1.90E+01 [fb]

Experimental Result: CMS-SUS-13-013 (efficiencyMap-type)
Theory prediction xsec =  4.16E-08 [pb]
Upper limit =  None
Expected Upper limit =  None

Experimental Result: CMS-SUS-13-019 (upperLimit-type)
Theory prediction xsec =  6.62E-04 [pb]
Upper limit =  9.70E+00 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-13-019 (upperLimit-type)
Theory prediction xsec =  3.07E-06 [pb]
Upper limit =  9.13E+00 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-13-019 (upperLimit-type)
Theory prediction xsec =  1.96E-03 [pb]
Upper limit =  3.76E+00 [fb]
Expected Upper limit =  None

Experimental Result: CMS-SUS-14-010 (upperLimit-type)
Theory prediction xsec =  3.07E-06 [pb]
Upper limit =  3.69E+00 [fb]
Expected Upper limit =  4.79E+00 [fb]
In [ ]: