Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:29:28

0001 #ifndef SIMCALORIMETRY_ECALTRIGPRIMALGOS_ECALFENIXFGVBEB_H
0002 #define SIMCALORIMETRY_ECALTRIGPRIMALGOS_ECALFENIXFGVBEB_H
0003 
0004 #include <cstdint>
0005 #include <vector>
0006 
0007 class EcalTPGFineGrainEBGroup;
0008 class EcalTPGFineGrainEBIdMap;
0009 
0010 /**
0011     \class EcalFenixFgvbEB
0012     \brief calculation of Fgvb for Fenix Tcp, format barrel
0013     *  calculates fgvb for the barrel
0014     *
0015     *
0016     *  input: 2X12 bits ( 12 bits Ettot + 12 bits maxof2)
0017     *  output: 1 bit
0018     *
0019     *
0020     *  makes comparisons between maxof2 and 2 fractions of Ettot and  uses this
0021    comparison to decide ---> needs to get some values from outside
0022     */
0023 class EcalFenixFgvbEB {
0024 private:
0025   uint32_t ETlow_, EThigh_, Ratlow_, Rathigh_, lut_;
0026   //    std::vector<int> adder_out_;
0027   //    std::vector<int> maxOf2_out_;
0028   //    std::vector<int> fgvb_out_;
0029   std::vector<int> add_out_8_;
0030 
0031 public:
0032   EcalFenixFgvbEB(int maxNrSamples);
0033   virtual ~EcalFenixFgvbEB();
0034   void setParameters(uint32_t towid,
0035                      const EcalTPGFineGrainEBGroup *ecaltpgFgEBGroup,
0036                      const EcalTPGFineGrainEBIdMap *ecaltpgFineGrainEB);
0037 
0038   void process(std::vector<int> &add_out, std::vector<int> &maxof2_out, std::vector<int> &output);
0039 };
0040 
0041 #endif