Back to home page

sPhenix code displayed by LXR

 
 

    


File indexing completed on 2025-08-05 08:18:28

0001 /* Copyright 2019, Belle II Collaboration
0002    Authors: Dmitrii Neverov
0003 
0004    This file is part of GENFIT.
0005 
0006    GENFIT is free software: you can redistribute it and/or modify
0007    it under the terms of the GNU Lesser General Public License as published
0008    by the Free Software Foundation, either version 3 of the License, or
0009    (at your option) any later version.
0010 
0011    GENFIT is distributed in the hope that it will be useful,
0012    but WITHOUT ANY WARRANTY; without even the implied warranty of
0013    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
0014    GNU Lesser General Public License for more details.
0015 
0016    You should have received a copy of the GNU Lesser General Public License
0017    along with GENFIT.  If not, see <http://www.gnu.org/licenses/>.
0018 */
0019 
0020 #include "RKTrackRep.h"
0021 
0022 namespace genfit {
0023   /**
0024    * Monopole track representation.
0025    * It is a minimal modification of RKTrackRep
0026    * with a different equations of motion for magnetic charges.
0027    *
0028    * In the current implementation the states on plane are 5-d:
0029    * u, v, u', v', q/p
0030    * except that q in this case is magnetic, and the monopole
0031    * has no electic charge.
0032    */
0033   class MplTrackRep : public RKTrackRep {
0034 
0035   public:
0036 
0037     MplTrackRep() : m_magCharge(0), m_mass(0) {};
0038     MplTrackRep(int pdgCode, float magCharge, char propDir = 0);
0039     ~MplTrackRep();
0040 
0041     // Hopefully this is the only function that is vastly different for monopoles
0042     double RKPropagate(M1x7& state7,
0043                        M7x7* jacobian,
0044                        M1x3& SA,
0045                        double S,
0046                        bool varField = true,
0047                        bool calcOnlyLastRowOfJ = false) const override;
0048 
0049     // Returns the magnetic charge instead of electric as in the base class.
0050     double getCharge(const StateOnPlane& state) const override; 
0051 
0052   private:
0053 
0054     const double m_magCharge; // the magnitude of magnetic charge in units of e+
0055     const double m_mass; // the mass of the monopole in units of GeV/c^2
0056 
0057 
0058   public:
0059 
0060     ClassDefOverride(MplTrackRep, 1)
0061 
0062   };
0063 } //end genfit namespace