Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:20:55

0001 #ifndef L1TMuonEndCap_PtAssignmentEngineAux2017_h
0002 #define L1TMuonEndCap_PtAssignmentEngineAux2017_h
0003 
0004 #include "L1Trigger/L1TMuonEndCap/interface/PtAssignmentEngineAux.h"
0005 
0006 class PtAssignmentEngineAux2017 : public PtAssignmentEngineAux {
0007 public:
0008   int getNLBdPhi(int dPhi, int bits = 7, int max = 512) const;
0009 
0010   int getNLBdPhiBin(int dPhi, int bits = 7, int max = 512) const;
0011 
0012   int getdPhiFromBin(int dPhiBin, int bits = 7, int max = 512) const;
0013 
0014   int getCLCT(int clct, int endcap, int dPhiSign, int bits = 3) const;
0015 
0016   int unpackCLCT(int clct, int endcap, int dPhiSign, int bits) const;
0017 
0018   int getdTheta(int dTheta, int bits = 3) const;
0019 
0020   int unpackdTheta(int dTheta, int bits) const;
0021 
0022   int getTheta(int theta, int ring2, int bits = 5) const;
0023 
0024   void unpackTheta(int& theta, int& st1_ring2, int bits) const;
0025 
0026   int unpackSt1Ring2(int theta, int bits) const;
0027 
0028   int get2bRPC(int clctA, int clctB, int clctC) const;
0029 
0030   void unpack2bRPC(int rpc_2b, int& rpcA, int& rpcB, int& rpcC) const;
0031 
0032   int get8bMode15(int theta, int st1_ring2, int endcap, int sPhiAB, int clctA, int clctB, int clctC, int clctD) const;
0033 
0034   void unpack8bMode15(int mode15_8b,
0035                       int& theta,
0036                       int& st1_ring2,
0037                       int endcap,
0038                       int sPhiAB,
0039                       int& clctA,
0040                       int& rpcA,
0041                       int& rpcB,
0042                       int& rpcC,
0043                       int& rpcD) const;
0044 
0045   // Need to re-check / verify this - AWB 17.03.17
0046   // int getFRLUT(int sector, int station, int chamber) const;
0047 
0048   // ___________________________________________________________________________
0049   // From here down, code was originally in PtLUTVarCalc.h
0050 
0051   int calcTrackTheta(const int th1,
0052                      const int th2,
0053                      const int th3,
0054                      const int th4,
0055                      const int ring1,
0056                      const int mode,
0057                      const bool BIT_COMP = false) const;
0058 
0059   void calcDeltaPhis(int& dPh12,
0060                      int& dPh13,
0061                      int& dPh14,
0062                      int& dPh23,
0063                      int& dPh24,
0064                      int& dPh34,
0065                      int& dPhSign,
0066                      int& dPhSum4,
0067                      int& dPhSum4A,
0068                      int& dPhSum3,
0069                      int& dPhSum3A,
0070                      int& outStPh,
0071                      const int ph1,
0072                      const int ph2,
0073                      const int ph3,
0074                      const int ph4,
0075                      const int mode,
0076                      const bool BIT_COMP = false) const;
0077 
0078   void calcDeltaThetas(int& dTh12,
0079                        int& dTh13,
0080                        int& dTh14,
0081                        int& dTh23,
0082                        int& dTh24,
0083                        int& dTh34,
0084                        const int th1,
0085                        const int th2,
0086                        const int th3,
0087                        const int th4,
0088                        const int mode,
0089                        const bool BIT_COMP = false) const;
0090 
0091   void calcBends(int& bend1,
0092                  int& bend2,
0093                  int& bend3,
0094                  int& bend4,
0095                  const int pat1,
0096                  const int pat2,
0097                  const int pat3,
0098                  const int pat4,
0099                  const int dPhSign,
0100                  const int endcap,
0101                  const int mode,
0102                  const bool BIT_COMP = false) const;
0103 
0104   void calcRPCs(int& RPC1,
0105                 int& RPC2,
0106                 int& RPC3,
0107                 int& RPC4,
0108                 const int mode,
0109                 const int st1_ring2,
0110                 const int theta,
0111                 const bool BIT_COMP = false) const;
0112 
0113   int calcBendFromPattern(const int pattern, const int endcap) const;
0114 
0115   void calcDeltaPhiSums(int& dPhSum4,
0116                         int& dPhSum4A,
0117                         int& dPhSum3,
0118                         int& dPhSum3A,
0119                         int& outStPh,
0120                         const int dPh12,
0121                         const int dPh13,
0122                         const int dPh14,
0123                         const int dPh23,
0124                         const int dPh24,
0125                         const int dPh34) const;
0126 };
0127 
0128 #endif