def buildModel(self):
        mA = ROOT.RooRealVar('mA', 'm_{A} [GeV]', 120.)
        tanb = ROOT.RooRealVar('tanb', 'tan#beta', 20.)
        pars = [mA, tanb]

        self.mssm_inputs = mssm_xs_tools(
            self.filename, True, 1
        )  # syntax: model filename, Flag for interpolation ('True' or 'False'), verbosity level

        self.doHistFuncForQQH(pars)
        self.PROC_SETS.append('qqh')

        self.doHistFuncForGGH(pars)
        self.PROC_SETS.append('ggh')

        for X in ['h', 'H']:
            self.doHistFuncFromXsecTools(
                X, "mass",
                pars)  # syntax: Higgs-Boson, mass attribute, parameters

        self.doHistFuncFromModelFile(None, "yukawa_deltab", pars)

        for X in ['h', 'H', 'A']:
            self.doHistFuncFromModelFile(X, "yukawa_top", pars)
            self.doHistFuncFromModelFile(X, "yukawa_bottom", pars)

            self.doHistFuncFromXsecTools(
                X, "br", pars
            )  # syntax: Higgs-Boson, xsec attribute, parameters, production mode

            self.doHistFuncFromXsecTools(
                X, "xsec", pars, production="gg"
            )  # syntax: Higgs-Boson, xsec attribute, parameters, production mode
            self.doHistFuncFromXsecTools(
                X, "xsec", pars, production="bb"
            )  # syntax: Higgs-Boson, xsec attribute, parameters, production mode
            self.add_ggH_at_NLO('xs_gg{X}{LC}', X)

            # ggH scale uncertainty
            self.doAsymPowSystematic(X, "xsec", pars, "gg", "scale")
            # ggH pdf+alpha_s uncertainty
            self.doAsymPowSystematic(X, "xsec", pars, "gg", "pdfas")
            # bbH total uncertainty
            self.doAsymPowSystematic(X, "xsec", pars, "bb", "total")

            self.SYST_DICT['xs_gg%s' % X].append('systeff_xs_gg%s_MSSM_scale' %
                                                 X)
            self.SYST_DICT['xs_gg%s' % X].append('systeff_xs_gg%s_MSSM_pdfas' %
                                                 X)
            for loopcontrib in ['t', 'b', 'i']:
                self.SYST_DICT['xs_gg%s_%s' % (X, loopcontrib)].append(
                    'systeff_xs_gg%s_MSSM_scale' % X)
                self.SYST_DICT['xs_gg%s_%s' % (X, loopcontrib)].append(
                    'systeff_xs_gg%s_MSSM_pdfas' % X)

            self.SYST_DICT['xs_bb%s' % X].append('systeff_xs_bb%s_MSSM_total' %
                                                 X)

            # Make a note of what we've built, will be used to create scaling expressions later
            self.PROC_SETS.append('bb%s' % X)
            self.PROC_SETS.extend(['gg%s_t' % X, 'gg%s_b' % X, 'gg%s_i' % X])

        # And the SM terms
        self.PROC_SETS.extend(['ggH125', 'qqH125', 'ZH125', 'WH125', 'ttH125'])
Example #2
0
    def buildModel(self):
        mass = ROOT.RooRealVar(
            self.massparameter,
            'm_{A} [GeV]' if self.massparameter == 'mA' else 'm_{H^{+}} [GeV]',
            160.)  # the other case would be 'mHp'
        tanb = ROOT.RooRealVar('tanb', 'tan#beta', 5.5)
        pars = [mass, tanb]

        self.mssm_inputs = mssm_xs_tools(
            self.filename, False, 1
        )  # syntax: model filename, Flag for interpolation ('True' or 'False'), verbosity level

        # qqphi, Zphi and Wphi  added always in this setup
        self.doHistFuncForQQH(pars)
        self.PROC_SETS.extend(
            ['qq' + self.smlike, 'Z' + self.smlike, 'W' + self.smlike])

        # adding ggphi & bbphi as 125 templates only if requested
        if self.replace_with_sm125:

            self.doHistFuncForGGH(pars)
            self.PROC_SETS.append('gg' + self.smlike)

            self.doHistFuncForBBH(pars)  # no need to add since added later

        procs = ['H1', 'H2', 'H3'
                 ] if self.scenario == "mh1125_CPV" else ['h', 'H', 'A']

        for X in procs:
            if self.massparameter.replace(
                    'm', ''
            ) == X:  # don't create histogram for 'A' in cases, where its mass is a model-parameter
                continue
            self.doHistFuncFromXsecTools(
                X, "mass",
                pars)  # syntax: Higgs-Boson, mass attribute, parameters

        for X in procs:
            if self.scenario == "mh1125_CPV":
                self.doHistFuncFromXsecTools(X,
                                             "interference",
                                             pars,
                                             production="gg")
                self.doHistFuncFromXsecTools(X,
                                             "interference",
                                             pars,
                                             production="bb")
            else:
                self.doHistFuncFromXsecTools(X, "yukawa_top", pars)
                self.doHistFuncFromXsecTools(X, "yukawa_bottom", pars)

            self.doHistFuncFromXsecTools(
                X, "br", pars
            )  # syntax: Higgs-Boson, xsec attribute, parameters, production mode

            self.doHistFuncFromXsecTools(
                X, "xsec", pars, production="gg"
            )  # syntax: Higgs-Boson, xsec attribute, parameters, production mode
            self.doHistFuncFromXsecTools(
                X, "xsec", pars, production="bb"
            )  # syntax: Higgs-Boson, xsec attribute, parameters, production mode

            self.add_ggH_at_NLO('xs_gg{X}{LC}', X)

            # ggH scale uncertainty
            self.doAsymPowSystematic(X, "xsec", pars, "gg", "scale")
            # ggH pdf+alpha_s uncertainty
            self.doAsymPowSystematic(X, "xsec", pars, "gg", "pdfas")
            # bbH total uncertainty
            self.doAsymPowSystematic(X, "xsec", pars, "bb", "total")

            for loopcontrib in ['t', 'b', 'i']:
                self.SYST_DICT['xs_gg%s_%s' % (X, loopcontrib)].append(
                    'systeff_xs_gg%s_MSSM_scale' % X)
                self.SYST_DICT['xs_gg%s_%s' % (X, loopcontrib)].append(
                    'systeff_xs_gg%s_MSSM_pdfas' % X)

            self.SYST_DICT['xs_bb%s' % X].append('systeff_xs_bb%s_MSSM_total' %
                                                 X)

            # Make a note of what we've built, will be used to create scaling expressions later
            self.PROC_SETS.append('bb%s' % X)
            if X != self.smlike:
                self.PROC_SETS.append('bb%s_lowmass' % X)
            self.PROC_SETS.extend([
                'gg%s_t' % X,
                'gg%s_b' % X,
                'gg%s_i' % X,
                'gg%s_t_lowmass' % X,
                'gg%s_b_lowmass' % X,
                'gg%s_i_lowmass' % X
            ])

        # Add BSM systematic also in case SM125 templates are used for ggphi and bbphi
        if self.replace_with_sm125:
            self.SYST_DICT["sf_ggphi_MSSM"].append(
                'systeff_xs_gg%s_MSSM_scale' % self.smlike)
            self.SYST_DICT["sf_ggphi_MSSM"].append(
                'systeff_xs_gg%s_MSSM_pdfas' % self.smlike)
            self.SYST_DICT["sf_bbphi_MSSM"].append(
                'systeff_xs_bb%s_MSSM_total' % self.smlike)

        # And the SM terms
        self.PROC_SETS.extend(['ggH125', 'qqH125', 'ZH125', 'WH125', 'bbH125'])
        if self.debug_output:
            self.debug_output.Close()