Double_t tpileup_mich(Double_t *t, Double_t *par) // Michel pileup pdf { double yield = 0.; double tau_pi = 26.03; double tau_mu = 2197.; double pg_start = -69.70; // opening of PiGate double pg_close = 222.50; // closing of PiGate double T = 19.75; // rf Period, ns if ( t[0] > pg_start && t[0] < pg_close ) { for (int n= -500; n<11; n++ ) { // 5 muon lifetimes into past if ( t[0]>n*T ) // causality yield+ = exp( (-t[0]+n*T)/tau_mu) - exp( (-t[0] + n*T)/tau_pi); } // end for return par[0]*yield; } // end if else return yield ; }