Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-08-06 09:20:02

0001 
0002 /***********************************************************************
0003 * Copyright 1998-2020 CERN for the benefit of the EvtGen authors       *
0004 *                                                                      *
0005 * This file is part of EvtGen.                                         *
0006 *                                                                      *
0007 * EvtGen is free software: you can redistribute it and/or modify       *
0008 * it under the terms of the GNU General Public License as published by *
0009 * the Free Software Foundation, either version 3 of the License, or    *
0010 * (at your option) any later version.                                  *
0011 *                                                                      *
0012 * EvtGen is distributed in the hope that it will be useful,            *
0013 * but WITHOUT ANY WARRANTY; without even the implied warranty of       *
0014 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *
0015 * GNU General Public License for more details.                         *
0016 *                                                                      *
0017 * You should have received a copy of the GNU General Public License    *
0018 * along with EvtGen.  If not, see <https://www.gnu.org/licenses/>.     *
0019 ***********************************************************************/
0020 
0021 #ifndef EVT_DALITZ_RES_PDF_HH
0022 #define EVT_DALITZ_RES_PDF_HH
0023 
0024 #include "EvtGenBase/EvtCyclic3.hh"
0025 #include "EvtGenBase/EvtDalitzPoint.hh"
0026 #include "EvtGenBase/EvtPdf.hh"
0027 
0028 /*
0029  * Pole compensating function for terms that exibit a resonant structure
0030  * in one dimension only.
0031  *
0032  * f =  1    g*m0
0033  *     --  ------------------
0034  *     pi  (q-q0)^2 + g^2m0^2
0035  *
0036  * m is the mass of the resonance, g is its width. The approximation works well for a narrow
0037  * resonance. It is also readily integrable over the Dalitz plot coordinate to produce
0038  *
0039  * Int = 1/pi atan((q-q0)/(g*m0))
0040  */
0041 
0042 class EvtDalitzResPdf : public EvtPdf<EvtDalitzPoint> {
0043   public:
0044     EvtDalitzResPdf( const EvtDalitzPlot& dp, double m0, double g0,
0045                      EvtCyclic3::Pair pairRes );
0046 
0047     EvtPdf<EvtDalitzPoint>* clone() const override
0048     {
0049         return new EvtDalitzResPdf( *this );
0050     }
0051 
0052     using EvtPdf<EvtDalitzPoint>::compute_integral;
0053     EvtValError compute_integral( int N ) const override;
0054     EvtDalitzPoint randomPoint() override;
0055     double pdfMaxValue() const;
0056 
0057   protected:
0058     double pdf( const EvtDalitzPoint& ) const override;
0059 
0060   private:
0061     EvtDalitzPlot _dp;
0062     double _m0;                // mass
0063     double _g0;                // width
0064     EvtCyclic3::Pair _pair;    // resonant pair
0065 };
0066 
0067 #endif