Back to home page

sPhenix code displayed by LXR

 
 

    


File indexing completed on 2025-08-05 08:12:06

0001 bool accept_electron( float eta, float p )
0002 {
0003   float Emin = 3;
0004 
0005   if ( p > Emin )
0006     {
0007       if ( ( eta > -4 && eta < 4 ) )
0008         {
0009           return true;
0010         }
0011     }
0012 
0013   return false;
0014 }
0015 
0016 
0017 bool accept_pion( float eta, float p )
0018 {
0019   float pmin = 1; // GeV
0020   bool accept = false;
0021 
0022   if ( p > pmin )
0023     {
0024       /* Particle found within PID acceptance for e-going mRICH? */
0025       if ( ( eta > 1.242 && eta < 1.85 && p < 6 ) )
0026     accept = true;
0027 
0028       /* Particle found within PID acceptance for barrel DIRC? */
0029       else if ( ( eta > -1.55 && eta < 1.242 && p < 6 ) )
0030     accept = true;
0031 
0032       /* Particle found within PID acceptance for h-going Gas-RICH? */
0033       else if ( ( eta > 1.242 && eta < 4 && p > 3 && p < 50 ) )
0034     accept = true;
0035 
0036       /* Particle found within PID acceptance for h-going mRICH? */
0037       else if ( ( eta > 1.242 && eta < 1.85 && p < 6 ) )
0038     accept = true;
0039 
0040       /* Particle found within PID acceptance for h-going TOF? */
0041       else if ( ( eta > 1.85 && eta < 4 && p < 5 ) )
0042     accept = true;
0043     }
0044 
0045   return accept;
0046 }
0047 
0048 
0049 bool accept_kaon( float eta, float p )
0050 {
0051   bool accept = false;
0052 
0053   accept = accept_pion( eta, p );
0054 
0055   return accept;
0056 }