Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

Pi0RecAlg Class Reference

#include <Pi0RecAlg.h>

List of all members.

Public Member Functions

StatusCode execute ()
StatusCode execute ()
StatusCode finalize ()
StatusCode finalize ()
StatusCode initialize ()
StatusCode initialize ()
 Pi0RecAlg (const std::string &name, ISvcLocator *pSvcLocator)
 Pi0RecAlg (const std::string &name, ISvcLocator *pSvcLocator)

Private Member Functions

HepLorentzVector getP4 (RecEmcShower *gTrk)
HepLorentzVector getP4 (RecEmcShower *gTrk)

Private Attributes

UserPi0Cut _pi0_cut


Constructor & Destructor Documentation

Pi0RecAlg::Pi0RecAlg const std::string &  name,
ISvcLocator *  pSvcLocator
 

00014                                                                     :
00015         Algorithm(name, pSvcLocator)
00016 {
00017         //Declare the properties
00018         declareProperty("EMinOfBarrel",       _pi0_cut.MinEnergyOfBarrelPhoton = 0.025);
00019         declareProperty("EMinOfEndcap",       _pi0_cut.MinEnergyOfEndcapPhoton = 0.045);
00020         declareProperty("Angle",       _pi0_cut.MinAngle = 20);
00021         declareProperty("TimeLimit",       _pi0_cut.TimeLimit = 20);
00022 
00023         declareProperty("Pi0MinMass",       _pi0_cut.MinMass = 0.10);
00024         declareProperty("Pi0MaxMass",       _pi0_cut.MaxMass = 0.18);
00025         declareProperty("ChisqCut",         _pi0_cut.Chisq = 50.0);
00026 }

Pi0RecAlg::Pi0RecAlg const std::string &  name,
ISvcLocator *  pSvcLocator
 


Member Function Documentation

StatusCode Pi0RecAlg::execute  ) 
 

StatusCode Pi0RecAlg::execute  ) 
 

00039                               {
00040 
00041         MsgStream log(msgSvc(), name());
00042         log << MSG::INFO << "in execute()" <<endreq;
00043 
00044         // get event header, eventlist and tracklist from TDS
00045         SmartDataPtr<Event::EventHeader> eventHeader(eventSvc(),"/Event/EventHeader");
00046         SmartDataPtr<EvtRecEvent> recEvt(eventSvc(), EventModel::EvtRec::EvtRecEvent);
00047         SmartDataPtr<EvtRecTrackCol> recTrkCol(eventSvc(),  EventModel::EvtRec::EvtRecTrackCol);
00048 
00049         bool save2TDS = false;
00050         SmartDataPtr<EvtRecPi0Col> recPi0Col(eventSvc(), EventModel::EvtRec::EvtRecPi0Col);
00051         if ( !recPi0Col ) {
00052                 recPi0Col = new EvtRecPi0Col;
00053                 save2TDS = true;
00054         }
00055         using namespace Pi0;
00056         //   std::cout<<"**********************************************"<<std::endl;
00057         static Criteria cri_inv(_pi0_cut.MinMass, _pi0_cut.MaxMass);
00058        
00059         //static KFitCriteria cri_kfit;
00060 
00061         UserPi0Cut::SetForTrack(recEvt, recTrkCol);
00062 
00063 //      Pi0::make_gamma_list(recEvt, recTrkCol);
00064         Pi0::make_gamma_list(_pi0_cut);
00065         Pi0::make_pi0_list(Pi0::GetDefaultGammaList());
00066         //              Pi0::print_gamma_list(Pi0::GetDefaultGammaList());
00067         Pi0::apply_criteria(cri_inv);
00068         Pi0::GetCandidatePi0List().sort(high_momentum());
00069         //      Pi0::print_pi0_list(Pi0::GetCandidatePi0List());
00070         Pi0::Pi0ListToTDS(Pi0::GetCandidatePi0List(), recPi0Col);
00071         //   std::cout<<"**********************************************"<<std::endl;
00072         if ( save2TDS ) {
00073                 StatusCode sc = eventSvc()->registerObject(EventModel::EvtRec::EvtRecPi0Col, recPi0Col);
00074                 if ( sc.isFailure() ) {
00075                         log << MSG::ERROR << "could not register EvtRecPi0Col in TDS" <<endreq;
00076                         return StatusCode::FAILURE;
00077                 }
00078         }
00079         return StatusCode::SUCCESS;
00080 }

StatusCode Pi0RecAlg::finalize  ) 
 

StatusCode Pi0RecAlg::finalize  ) 
 

00084                                {
00085 
00086         MsgStream log(msgSvc(), name());
00087         log << MSG::INFO << "in finalize()" << endreq;
00088 
00089         return StatusCode::SUCCESS;
00090 }

HepLorentzVector Pi0RecAlg::getP4 RecEmcShower gTrk  )  [private]
 

HepLorentzVector Pi0RecAlg::getP4 RecEmcShower gTrk  )  [private]
 

00092                                                     {
00093 
00094         double eraw = gTrk->energy();
00095         double phi =  gTrk->phi();
00096         double the =  gTrk->theta();
00097 
00098         return HepLorentzVector( eraw * sin(the) * cos(phi),
00099                         eraw * sin(the) * sin(phi),
00100                         eraw * cos(the),
00101                         eraw );
00102 }

StatusCode Pi0RecAlg::initialize  ) 
 

StatusCode Pi0RecAlg::initialize  ) 
 

00029                                  {
00030 
00031         MsgStream log(msgSvc(), name());
00032         log << MSG::INFO << "in initialize()" <<endreq;
00033 
00034         return StatusCode::SUCCESS;
00035 }


Member Data Documentation

UserPi0Cut Pi0RecAlg::_pi0_cut [private]
 


The documentation for this class was generated from the following files:
Generated on Wed Feb 2 16:40:35 2011 for BOSS6.5.5 by  doxygen 1.3.9.1