// Sara Vanini: main program muon radiography for EM reconstruction // June, 10th 2008 #include #include #include #include #include #include #include using std::string; // root classes #include "TH1F.h" #include "TFile.h" #include "TRandom.h" // algorithm parameters int iterNum = 10; // number of iterations bool dump_root = true; // global variables TFile * fout; // useful histograms TH1F * hlambda[10]; int main() { fout = new TFile("EM.root","recreate"); // init histograms for(int i=0; iSetDirectory(fout); } // iterations TRandom * rand = new TRandom; for(int it=0; itRndm(); hlambda[it]->Fill(lambda_j_new); } }// end iterations if(dump_root) { // *** Draw histograms just for sanity check and save them to file for(int i=0; iWrite(); fout->Close(); } } return 0; }