/* $Id: CbmRichAnalysis.C,v 1.1 2005/06/24 15:23:47 kharlov Exp $ */ /* History of cvs commits: * * $Log: CbmRichAnalysis.C,v $ * Revision 1.1 2005/06/24 15:23:47 kharlov * First adaptation of RICH scripts for cbmroot2 * */ void CbmRichAnalysis(Float_t wl_cut=100.) { //Simple macro to run RICH analysis. //wl_cut is UV cutoff (nm), so RICH photodetector is blind for Cherenkov photons //with wavelength lambda CbmRichHitsProd.C --> CbmRichRingGuidanceProd.C --> // --> CbmRichAnalysisHits.C. gROOT->LoadMacro("$VMCWORKDIR/gconfig/basiclibs.C"); basiclibs(); gSystem->Load("libGeoBase"); gSystem->Load("libBase"); gSystem->Load("libPassive"); gSystem->Load("libSts"); gSystem->Load("libTof"); gSystem->Load("libRich"); gSystem->Load("libTrd"); gSystem->Load("libEcal"); gSystem->Load("libGen"); CbmRunAna *fRun = new CbmRunAna(); CbmRuntimeDb *rtdb = fRun->GetRuntimeDb(); CbmParRootFileIo *io1 = new CbmParRootFileIo(); io1->open("parfiles/testparams.root"); rtdb->setFirstInput(io1); fRun->SetInputFile("Electron.root"); fRun->AddFriend("Electron_hit.root"); fRun->AddFriend("Electron_rg.root"); fRun->SetOutputFile("Electron_analysis.root"); CbmRichPhotodetector* phd = CbmRichPhotodetector::GetInstance(); phd->SetLambdaMin(wl_cut); CbmRichAnalysisHits *ana = new CbmRichAnalysisHits("Hit Analysis"); // ana->SetDebug("primmcphitringuid"); // ana->SetDebug("ring+"); fRun->AddTask(ana); fRun->Init(); fRun->Run(); delete ana; }