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

NCExtraction.cxx

Go to the documentation of this file.
00001 
00002 //$Id: NCExtraction.cxx,v 1.17 2009/09/12 16:26:51 rodriges Exp $
00003 //
00004 //NCExtraction.cxx
00005 //
00006 //class to hold pdfs for doing nccc separation
00007 //
00008 //B. Rebel 10/2005
00010 
00011 #include "NCUtils/Extraction/NCExtraction.h"
00012 #include "NCUtils/Cuts/NCAnalysisCutsNC.h"
00013 #include "NCUtils/NCType.h"
00014 
00015 #include "AnalysisNtuples/ANtpAnalysisInfo.h"
00016 #include "MessageService/MsgService.h"
00017 #include "Conventions/SimFlag.h"
00018 
00019 CVSID("$Id: NCExtraction.cxx,v 1.17 2009/09/12 16:26:51 rodriges Exp $");
00020 
00021 //.......................................................................
00022 NCExtraction::NCExtraction(NCAnalysisCuts* cuts,
00023                            const Registry& r)
00024 {
00025   fCuts = cuts;
00026   fReleaseType=ReleaseType::kUnknown;
00027   int tmpi;
00028   if (r.Get("MCVersion", tmpi)) fReleaseType=(ReleaseType::Release_t)tmpi;
00029 }
00030 
00031 //-----------------------------------------------------------------------
00032 void NCExtraction::FillAnalysisInfo(NCEventInfo& evtInfo,
00033                                     int beamType)
00034 {
00035   ANtpAnalysisInfo* ana=evtInfo.analysis;
00036   double separationParameter=GetIdProbability(evtInfo, beamType);
00037   double separationCut=GetCutPosition();
00038 
00039   int interactionType = NCType::kUnknown;
00040   if(separationParameter < separationCut)
00041     interactionType = NCType::kNC;
00042   else if(separationParameter >= separationCut)
00043     interactionType = NCType::kCC;
00044 
00045 
00046   //reset the values
00047   ana->Reset();
00048 
00049   ana->separationParameterCut = separationCut;
00050   ana->separationParameter = separationParameter;
00051   ana->isNC = 0;
00052   ana->isCC = 0;
00053   if(interactionType == NCType::kNC) ana->isNC = 1;
00054   else if(interactionType == NCType::kCC) ana->isCC = 1;
00055 }
00056 

Generated on Mon Feb 15 11:07:03 2010 for loon by  doxygen 1.3.9.1