#include "PndTpcPoint.h" #include "TFile.h" #include "TError.h" #include "TClonesArray.h" #include "TTree.h" #include "TH1D.h" #include "TString.h" #include "TF1.h" #include "TCanvas.h" #include #include #include #include #include void analize(std::string filename) { TFile* inFile = new TFile(filename.c_str()); TTree* tree = (TTree*) inFile->Get("cbmsim"); TClonesArray* points = new TClonesArray("PndTpcPoint"); int nE=0; if(tree!=0) { tree->SetBranchAddress("PndTpcPoint", &points); nE = tree->GetEntries(); } std::cout<<"found "<Close(); double totalcharge=0.; std::cout<<"\nStarting loop over events ..."<GetEvent(ev); int nP = points->GetEntriesFast(); for(int p=0; pAt(p); totalcharge+=the_point->GetEnergyLoss(); } } std::cout<<"\n\nTotal accumulated charge before ionization was :"<