//Declarations Int_t nbBin; Int_t i; Int_t binL[20], binH[20]; Int_t maxZ; Double_t sS; Double_t excitE; TString tempTitle; TString zTitle; TString cTitle; TString binTitle; TString systemName; char histTemp; TH1F *histZ[50]; TH1F *hz; TH2F *histCampi[50]; TH2F *hc; //read files to create system specific histograms bin >> nbBin; for(i=1; i <= nbBin; i++) { binTitle.ReadLine(bin); bin >> binL[i] >> binH[i]; systemHist >> histTemp; title = systemName + zTitle + binTitle; histZ[i] = new TH1F(histTemp, title, 15,0,14); systemHist >> histTemp; title = systemName + cTitle + binTitle; histCampi[i] = new TH2F(histTemp, title, 150,0,14.9,150,0,14.9); }//end for(i=0; i < nbBin; i++) systemHist >> histTemp; tempTitle = " - Campi Plot - All E* Energys"; title = systemName + tempTitle; histCampi[0] = new TH2F(histTemp, title , 150,0,14.9,150,0,14.9); //fill historgrams for Z distributions and Campi Plots histCampi[0] -> Fill ( sS , maxZ ); histTotalCampi[0] -> Fill ( sS , maxZ ); for(i=1; i <= nbBin; i++) { hc = histCampi[i]; htc = histTotalCampi[i]; hz = histZ[i]; htz = histTotalZ[i]; if (excitE <= binH[i]) { if (excitE > binL[i]) { hc -> Fill ( sS , maxZ ); htc -> Fill( sS , maxZ ); for(Int_t j = 0; j < mult; j++) { hz -> Fill (zz[j]); htz -> Fill(zz[j]); }//end for(Int_t j = 0; j < mult; j++) }//end if (excitE > .5) }//end if (excitE <= .8) }//end for(i=1; i <= nbBin; i++)