CMS 3D CMS Logo

CMSCGENnorm Class Reference

#include <GeneratorInterface/CosmicMuonGenerator/interface/CMSCGENnorm.h>

List of all members.

Public Member Functions

 CMSCGENnorm ()
int events_n100cos (double energy, double theta)
float norm (int n100cos)
 ~CMSCGENnorm ()

Private Attributes

float flux
int n
int n100
int n100cos
float Nnorm


Detailed Description

Definition at line 31 of file CMSCGENnorm.h.


Constructor & Destructor Documentation

CMSCGENnorm::CMSCGENnorm (  )  [inline]

Definition at line 45 of file CMSCGENnorm.h.

References n100, and n100cos.

00045                {
00046     n100=0; 
00047     n100cos=0;
00048 }

CMSCGENnorm::~CMSCGENnorm (  )  [inline]

Definition at line 51 of file CMSCGENnorm.h.

References n100, and n100cos.

00051                 {
00052     n100=0; 
00053     n100cos=0;
00054 }


Member Function Documentation

int CMSCGENnorm::events_n100cos ( double  energy,
double  theta 
)

Definition at line 15 of file CMSCGENnorm.cc.

References funct::cos(), n100, n100cos, and Pi.

Referenced by CosmicMuonGenerator::nextEvent(), and CosmicMuonGenerator::terminate().

00016 {
00017    if(energy > 99.5 && energy < 100.5){ 
00018     n100=n100+1;
00019     
00020     if(1.-cos(theta) < 1./(2.*Pi)) { //theta is in rad
00021       n100cos = n100cos + 1 ;
00022     }
00023   }
00024   return n100cos;
00025 }

float CMSCGENnorm::norm ( int  n100cos  ) 

Definition at line 31 of file CMSCGENnorm.cc.

References flux, n, and Nnorm.

Referenced by CosmicMuonGenerator::terminate().

00032 { 
00033   flux = 2.63e-3 ; // +- 0.06e-3 [1/m**2/sr/GeV/s]
00034 
00035   n = n100cos ; // [1/sr/GeV]
00036   
00037   //rate=N/runtime --> Nnorm ~ (1/runtime/m^2 at surface plane) as rate corresponds to known flux
00038   Nnorm = flux/n ;
00039 
00040   //err of Nnorm = Nnorm* 1/sqrt(n)
00041   
00042   return Nnorm; 
00043 }


Member Data Documentation

float CMSCGENnorm::flux [private]

Definition at line 39 of file CMSCGENnorm.h.

Referenced by norm().

int CMSCGENnorm::n [private]

Definition at line 38 of file CMSCGENnorm.h.

Referenced by norm().

int CMSCGENnorm::n100 [private]

Definition at line 36 of file CMSCGENnorm.h.

Referenced by CMSCGENnorm(), events_n100cos(), and ~CMSCGENnorm().

int CMSCGENnorm::n100cos [private]

Definition at line 37 of file CMSCGENnorm.h.

Referenced by CMSCGENnorm(), events_n100cos(), and ~CMSCGENnorm().

float CMSCGENnorm::Nnorm [private]

Definition at line 40 of file CMSCGENnorm.h.

Referenced by norm().


The documentation for this class was generated from the following files:
Generated on Tue Jun 9 18:16:22 2009 for CMSSW by  doxygen 1.5.4