Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2024-09-28 07:02:49

0001 #ifndef __PID_H__
0002 #define __PID_H__
0003     
0004 //
0005 //  Hello PID Fans:
0006 //
0007 //  This is the base class for a simple set of objects that 
0008 //  are used to evaluate various detector technology choices for the EIC.
0009 //
0010 //  The idea is simple.  Regardless of PID detector technology choice 
0011 //  one must be able to answer some simple questions.  This virtual base class
0012 //  organizes the method of asking and answering these simple questions to
0013 //  allow for efficient and apples-to-apples comparisons.
0014 //  
0015 //  The base class requires that any derived class procide responses to several queries:
0016 //   -- valid   (double eta, double p                      );
0017 //   -- numSigma(double eta, double p,        PID::type PID);
0018 //   -- maxP    (double eta, double numSigma, PID::type PID);
0019 //   -- minP    (double eta, double numSigma, PID::type PID);
0020 //   -- name    ();
0021 //
0022 //  Here PID::type is an enumerated constant set allowing one to choose pi-vs-k or k-vs-p etc...
0023 //
0024 //  The detector types that inherit from PID will clearly have parameters that define their 
0025 //  performance and these are expected to be arguments of the constructor of those derived classes.
0026 //  For example:
0027 //     PID* tof = new tofBarrel(radius, etaLow, etaHigh, sigmaT);
0028 //
0029 //
0030 
0031 #include <string>
0032     
0033 class PID
0034 {
0035 public:
0036   PID() {}
0037   virtual ~PID() {}
0038     
0039   enum type {pi_k , k_p};
0040 
0041   virtual bool   valid    (double eta, double p                      )=0;
0042   virtual double numSigma (double eta, double p,        PID::type PID)=0;
0043   virtual double maxP     (double eta, double numSigma, PID::type PID)=0;
0044   virtual double minP     (double eta, double numSigma, PID::type PID)=0;
0045   virtual std::string name()=0;
0046   virtual void description()=0;
0047         
0048 protected:
0049     
0050 };
0051     
0052 #endif /* __PID_H__ */