Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 10:11:21

0001 /*****************************************************************************
0002  * Project: RooFit                                                           *
0003  * Package: RooFitCore                                                       *
0004  *    File: $Id$
0005  * Authors:                                                                  *
0006  *   WV, Wouter Verkerke, UC Santa Barbara, verkerke@slac.stanford.edu       *
0007  *   DK, David Kirkby,    UC Irvine,         dkirkby@uci.edu                 *
0008  *                                                                           *
0009  * Copyright (c) 2000-2005, Regents of the University of California          *
0010  *                          and Stanford University. All rights reserved.    *
0011  *                                                                           *
0012  * Redistribution and use in source and binary forms,                        *
0013  * with or without modification, are permitted according to the terms        *
0014  * listed in LICENSE (http://roofit.sourceforge.net/license.txt)             *
0015  *****************************************************************************/
0016 #ifndef ROO_EXTENDED_TERM
0017 #define ROO_EXTENDED_TERM
0018 
0019 #include "RooAbsPdf.h"
0020 #include "RooRealProxy.h"
0021 
0022 class RooExtendedTerm : public RooAbsPdf {
0023 public:
0024 
0025   RooExtendedTerm() = default;
0026   RooExtendedTerm(const char *name, const char *title, const RooAbsReal& n) ;
0027   RooExtendedTerm(const RooExtendedTerm& other, const char* name=nullptr) ;
0028   TObject* clone(const char* newname) const override { return new RooExtendedTerm(*this,newname) ; }
0029 
0030   double evaluate() const override { return 1. ; }
0031 
0032   ExtendMode extendMode() const override { return CanBeExtended ; }
0033   /// Return number of expected events, in other words the value of the associated n parameter.
0034   double expectedEvents(const RooArgSet* nset) const override ;
0035 
0036   std::unique_ptr<RooAbsReal> createExpectedEventsFunc(const RooArgSet* nset) const override;
0037 
0038 protected:
0039 
0040   RooRealProxy _n ;          ///< Number of expected events
0041 
0042   ClassDefOverride(RooExtendedTerm,1) // Meta-p.d.f flat in all observables introducing only extended ML term
0043 };
0044 
0045 #endif