/////////////////////////////////////////////////////////////////////
// 
// Dalitz decay following Ref. 12,15
// 
//                                  Author:  I. Froehlich
/////////////////////////////////////////////////////////////////////


using namespace std;
#include <sstream>
#include <iostream>
#include <iomanip>

#include "PDalitzDecay.h"


ClassImp(PDalitzDecay)

PDalitzDecay::PDalitzDecay()  {
};

PDalitzDecay::PDalitzDecay(const Char_t *id, const Char_t *de, Int_t key) :
    PChannelModel(id, de, key) {

    if (is_channel < 0)
	Warning("PDalitzDecay", "This model should be bound to CHANNELS only");

    //set all needed parameters in advance
    alpha = 1./137.0359895;
    mass_pi0 = makeStaticData()->GetParticleMass("pi0");
    mass_n   = makeStaticData()->GetParticleMass("n");
    mass_eta = makeStaticData()->GetParticleMass("eta");
    mass_p   = makeStaticData()->GetParticleMass("p");
    p1   = 4.*alpha/(3.*TMath::Pi());
    p2   = 0.5*p1;
    p3   = 0.5*p2*alpha;
    //--> from PData

    Int_t tid[11];
    tid[0] = 10; 
    makeStaticData()->GetDecayModeByKey(primary_key, tid); // retrieve current mode info
    parent_id = makeStaticData()->GetDecayParentByKey(primary_key);

    if (tid[0] != 2) 
	Warning("PDalitzDecay", "Only 2 body decay");

    //ee or mumu?
    if (makeStaticData()->IsParticle(tid[1], "dilepton") ||
	makeStaticData()->IsParticle(tid[2], "dilepton")) 
	sw=0;
    else if (makeStaticData()->IsParticle(tid[1], "dimuon") ||
	     makeStaticData()->IsParticle(tid[2], "dimuon")) 
	sw=1;
    else 
	Warning("PDalitzDecay", "%s: No dilepton/dimuon", de);

    if (makeStaticData()->IsParticle(tid[1], "dilepton") ||
	makeStaticData()->IsParticle(tid[1], "dimuon")) {
	dilepton_position = 1;
	dilepton_pid      = tid[1];
	others_position   = 2;
	other_pid         = tid[2];
    } else {
	dilepton_position = 2;
	dilepton_pid      = tid[2];
	others_position   = 1;
	other_pid         = tid[1];
    }

    if (sw==0) { // e+e-
	mass_e  = makeStaticData()->GetParticleMass("e-"); 
	mass_ee = 2.*mass_e;
    } 
    else { // mu+mu-
	mass_e  = makeStaticData()->GetParticleMass("mu-"); 
	mass_ee = 2.*mass_e;
    } //--> from PData
    
    mass_x = 0.;

    if (makeStaticData()->IsParticle(parent_id, "pi0") ||
	makeStaticData()->IsParticle(parent_id, "eta") ||
	makeStaticData()->IsParticle(parent_id, "eta'") ||
	makeStaticData()->IsParticle(parent_id, "J/Psi")) 
	flag = 1;
    else if (makeStaticData()->IsParticle(parent_id, "w")) {
	flag   = 2;
	mass_x = mass_pi0;
    } else if (makeStaticData()->IsParticle(parent_id, "D0") || 
	     makeStaticData()->IsParticle(parent_id, "NS110")) {
	flag   = 3;
	mass_x = mass_n;
    } else if (makeStaticData()->IsParticle(parent_id, "D+") || 
	     makeStaticData()->IsParticle(parent_id, "NS11+")) {
	flag   = 3;
	mass_x = mass_p;
    } else if (makeStaticData()->IsParticle(parent_id, "pn")) { 
	flag   = 3;
	mass_x = mass_p+mass_n;
    } else if (makeStaticData()->IsParticle(parent_id,"phi")) {
	flag   = 2;
	mass_x = mass_eta; //BUGBUG-> Are we sure about the mass_x? Needs additional checks
    } else {
	flag = 4;
    }

    //-->used for FDalitz
    pi0        = makeStaticData()->GetParticleID("pi0");
    eta        = makeStaticData()->GetParticleID("eta"); 
    eta_prime  = makeStaticData()->GetParticleID("eta'");
    w          = makeStaticData()->GetParticleID("w"); 
    Delta_0    = makeStaticData()->GetParticleID("D0"); 
    Delta_plus = makeStaticData()->GetParticleID("D+"); 
    phi        = makeStaticData()->GetParticleID("phi");
    S11_0      = makeStaticData()->GetParticleID("NS110"); 
    S11_plus   = makeStaticData()->GetParticleID("NS11+");

    useQED = 0;
    flatMD = 0;

    if (sw == 0) 
	ml = makeStaticData()->GetParticleMass("dilepton");    // dilepton mass threshold
    else 
	ml = makeStaticData()->GetParticleMass("dimuon");

    mass_parent = makeStaticData()->GetParticleMass(parent_id); 
    draw_parent_mass = -1.; //only for draw option

    rejection_flag = (makeStaticData()->IsParticle(parent_id,"eta'")) ? 1 :   // eta'
	((makeStaticData()->IsParticle(parent_id,"w")) ? 2 :     // w with mass > pole
	 0);                           // all the other cases
    photon_br = PhotonBR(parent_id);
    integral  = NULL;

    formfactor_model = NULL;
};

PDistribution* PDalitzDecay::Clone(const char *) const {
    return new PDalitzDecay((const PDalitzDecay &)* this);
};

Bool_t PDalitzDecay::Init(void) {
    //Init function called once for each PChannel
    
    //looking for parent. This is mandatory
    parent = GetParticle("parent");
    if (!parent) {
	Warning("Init", "Parent not found");
	return kFALSE;
    }

    PParticle *daughter1 = GetParticle("daughter");
    PParticle *daughter2 = GetParticle("daughter");
    if ((daughter1->ID() == makeStaticData()->GetParticleID("dilepton")) ||
	(daughter1->ID() == makeStaticData()->GetParticleID("dimuon"))) {
	other    = daughter2;
 	dilepton = daughter1;
    }
    else {
	other    = daughter1;
 	dilepton = daughter2;
    }
    
    return kTRUE;
};

Bool_t PDalitzDecay::FreezeOut(void) {
    formfactor_model = GetSecondaryModel("formfactor");
    return kTRUE;
};

int PDalitzDecay::GetDepth(int i) {
    if (i) return -1; //no Hdepth
    return 0;
}

Bool_t PDalitzDecay::SampleMass(void) {
    //Mass-sampling wrapper
    Double_t masses[3]; //parent + daughter masses
    //It is important that the orders are the same as in data base
    masses[0]                 = parent->M();
    masses[others_position]   = other->M();
    masses[dilepton_position] = dilepton->M();

    SampleMass(&masses[0]); //Call Coupled-Channel wrapper

    other->SetM(masses[others_position]);
    
    dilepton->SetM(masses[dilepton_position]);
    return kTRUE;
};

Bool_t PDalitzDecay::SampleMass(Double_t *mass, Int_t *) {
    sampleMD(mass[0], parent_id, 
	     mass[dilepton_position], mass[others_position]);
    return kTRUE;
};

Double_t PDalitzDecay::GetWeight(void) {
    //Wrapper
    Double_t masses[3]; //parent + daughter masses
    //It is important that the orders are the same as in data base
    masses[0] = parent->M();
    masses[others_position]   = other->M();
    masses[dilepton_position] = dilepton->M();

#if 0
    //the following lines are for the normalization of the weight integral
    //as a function of the parents mass
    //otherwise we get artefacts when using the weight option of Pluto
    if (!integral) {
	Int_t maxmesh=200;
	Double_t mmin=PData::LMass(parent->ID());   // mass threshold
	Double_t mmax=PData::UMass(parent->ID());   // mass ceiling
	
	Double_t dm=(mmax-mmin)/(maxmesh-1.); // mass increment for the mesh
	integral = new PMesh(maxmesh,"mesh2");
	integral->SetMin(mmin);
	integral->SetMax(mmax);
	for (int j=0;j<maxmesh;++j) {  // loop over the mesh points [0-200]
	    Double_t local_int=0;
	    Double_t mm=mmin+j*dm;            // update mass on the mesh
	    for (int i=0;i<1000;i++) {
		sampleMD(mm, parent_id, 
			 masses[dilepton_position], masses[others_position]);
		local_int+=dGdM(parent_id,masses[dilepton_position],mm);

	    }
	    integral->SetNode(j,local_int/1000.);
	    //cout << local_int << endl;
	}
	masses[0]=parent->M();
	masses[others_position]=other->M();
	masses[dilepton_position]=dilepton->M();
    }
#endif
    // return GetWeight(&masses[0])/integral->GetLinearIP(masses[0]); //Call Coupled-Channel wrapper
    // return GetWeight(&masses[0]);

    //Pluto weight should be in units of probability
     return (GetWeight(&masses[0]) / 
	     makeDynamicData()->GetParticleTotalWidth(parent->M(),parent_id));
     // return GetWeight(&masses[0]) / 
     //	makeStaticData()->GetParticleTotalWidth(parent_id);
};

Double_t PDalitzDecay::GetWeight(Double_t *mass, Int_t *) {
    Double_t dgdm = dGdM(parent_id, mass[dilepton_position], mass[0]);
    //    Double_t dgdm = FDalitz(parent_id,mass[dilepton_position],mass[0]);

    return dgdm;
};

Bool_t PDalitzDecay::GetWidth(Double_t mass, Double_t *width, Int_t) {
    if (makeStaticData()->GetPWidx(is_channel) == -1) 
	return 0.; // Disabled --> BUGBUG why not static?

    if (!makeStaticData()->GetPWidx(is_channel) || width_init == 0) { // Enter below only on the first call

	width_init++;
	makeDynamicData()->GetParticleDepth(parent_id); // if 1st call will initialize flags

	mmin=makeStaticData()->GetDecayEmin(is_channel);  // mass threshold for the decay
	Double_t w0 = 1.;      // starting weight
	
	if (PData::IsMDalitz(is_channel)) 
	    w0 = photon_br;// if meson Dalitz decay...
	// ...then scale by BR of the corresponding real-photon decay (from PBR[] table)
	mmax = PData::UMass(parent_id);                // mass ceiling
	Double_t dm = (mmax-mmin)/(maxmesh-3.);          // mass increment

	double mass_threshold, mass_ceiling;
	mass_threshold = PData::LMass(dilepton_pid);
	mass_ceiling   = PData::LMass(other_pid);

#ifdef INGO_DEBUG
	Info("GetWidth", "Creating mesh in %s (%f,%f)", makeStaticData()-> GetDecayName(is_channel),
	     mass_threshold, mass_ceiling);
#endif
    
	mesh = new PMesh(maxmesh-2, "mesh");
	for (int i=0; i<maxmesh-2; ++i) {
	    Double_t mm = mmin+i*dm;   // current invariant mass of the parent resonance

	    Double_t temp0 = 0.;
	    mc_max = 10000;
	    for (int mc=0; mc<mc_max; mc++)  {
		Double_t running_ee_mass = mass_threshold+((Double_t(mc)/Double_t(mc_max))
							   *(mm-mass_threshold-mass_ceiling));
		if (running_ee_mass > mass_threshold)
		    temp0 += dGdM(parent_id, running_ee_mass, mm);
	    }

	    temp0 /= mc_max;

	    temp0 *= w0;
	    temp0 *= (mm-mass_ceiling);
	    mesh->SetNode(i, temp0);
	}

	mesh->SetMin(mmin);                 // store mass threshold
	mesh->SetMax(mmax);                 // store mass ceiling
	makeStaticData()->SetPWidx(is_channel, 1);  //Enable channel
    } //END first call

    if (mesh)  {
	*width = mesh->GetLinearIP(mass);
	return kTRUE;
    }
    return kFALSE;
};

Double_t PDalitzDecay::EvalPar(const Double_t *x, const Double_t *) {
    return Eval(x[0]);
};
 
Double_t PDalitzDecay::Eval(Double_t x, Double_t, Double_t, Double_t) const {
    //Draw the Dalitz FF as a function of the dilepton mass
    Double_t res;
    Double_t mass[3];

    mass[0] = makeStaticData()->GetParticleMass(parent_id); 
    if (draw_parent_mass > 0) 
	mass[0] = draw_parent_mass;
    mass[dilepton_position] = x;
    mass[others_position]   = mass_x;

    if (draw_option == 0) {
	return ((PChannelModel*)this)->GetWeight(mass);
	//return res;
    }
    if (draw_option == 1) {
	((PChannelModel*)this)->GetWidth(x, &res);
	return res;
    }
    if (draw_option == 2) {
	((PChannelModel*)this)->GetBR(x, &res);
	return res;
    }
    return 0;
};

double PDalitzDecay::dGdM(const int &id, const double &m, const double &ecm) {
    // Dalitz dilepton dG/dM, the dilepton mass distribution function (Refs. 12, 8)
    // arguments: id=parent hadron, m=dilepton mass, ecm=invariant mass
    // Note: the returned value in the case of Delta0 or Delta+ is the decay width,
    //       but it is the branching ratio for meson Dalitz decays. In the latter
    //       case the real-photon mode static branching ratio scales dG/dM (Ref. 8)
    //       See Ref. 4 eqs. 3.30, 3.31, 3.36, 3.37 for details.
    //
    // (copied and adapted from PData, IF)


    if (m<mass_ee || m>ecm-mass_x) return 0.;
    
    double f1 = mass_e/m, 
	f2 = f1*f1, 
	a = 1.-4.*f2,
	b = 1.+2.*f2, 
	y = sqrt(a)*b/m, c, 
	z = -1;

    switch (flag) {
    case 1:                 // pseudoscalar meson
	c = m/ecm;
	z = 1.-c*c;
	z *= p1*z*z;          // Ref 12 Eq. 3.36
		
	break;
    case 2:                 // vector meson (w)
	c = ecm*ecm;
	c = m/(c-mass_x*mass_x);
	z = 1.+m*c;
	z *= z;
	c *= 2.*ecm;
	z -= c*c;
	z *= p2*sqrt(z);      // Ref 12 Eq. 3.37
	break;
    case 3:                 // Delta resonance, N1535 or pn bremsstrahlung
	z = p3*PKinematics::pcms(ecm,mass_x,m)/(ecm*ecm);
	//	    z *= makeStaticData()->GetParticleTotalWidth(id)/0.12; // fix an asymmetry in the treatment of
	// leptonic vs. hadronic decays
	// (compare treatment of width in HWidth())
	break;
    case 4:
	Warning("dGdM", "Unknown decay");
	// nothing known
	break;
    }

    return y * z * FDalitz(id, m, ecm);
}

double PDalitzDecay:: FDalitz(const int &id, const double &m, double ecm) {
    // Matrix element squared for Dalitz decay (Ref 4).
    // Form factor for pseudoscalars

    double f = 0., m2 = m*m;

    if (id==Delta_0 || id==S11_0 || id==Delta_plus || id==S11_plus) {
	// For Delta, N* we need the matrix element in addition
	Double_t mn = 0.;
	if (id==Delta_0 || id==S11_0) 
	    mn = mass_n;
	else if (id==Delta_plus || id==S11_plus) 
	    mn = mass_p;
	double mm = ecm+mn;
	double ff = 2.7;
	if (formfactor_model)
	    ff = formfactor_model->GetWeight((Double_t*)&m);
	f = ff*mm/(2.*mn*(mm*mm-m2));
	double md = ecm, md2 = md*md, md3 = md2*md, md4 = md3*md,
	    mn2 = mn*mn, mn4 = mn2*mn2, m4 = m2*m2,
//	sum = (mn-m-md)*(mn+m-md)*         // Eq. 3.54 of Ref 4
//	    sum = (1./9.)*((md-mn)*(md-mn)-m2)*   //from PRC 58, 447
	    sum = ((md-mn)*(md-mn)-m2)*
	    (7.*md4 + 14.*md2*m2 + 3.*m4 + 8.*md3*mn + 2.*md2*mn2 + 
	     6.*m2*mn2 + 3.*mn4);
	return sum*f*f;
    }

    if (useQED) return 1.;   // QED form factor 
    //Self-defined form factor
    if (formfactor_model) {
	double ff = formfactor_model->GetWeight((Double_t*)&m);
	return ff;
    }

    if (id == pi0) {
	f = (1.+5.5*m2);
	return f*f;
    } else if (id == eta) {
	f = 1.-m2/0.5184;
	return 1./(f*f);
    } else if (id == eta_prime) 
	return 0.33939776/( (0.5776-m2)*(0.5776-m2) + 0.005776);
    else if (id == w)
	return 0.17918225/( (0.4225-m2)*(0.4225-m2) + 0.000676);
    else if (id == phi) {
	f = 1.-m2/(0.77*0.77);
	return 1./(f*f); 
    } else if (id == makeStaticData()->GetParticleID("J/Psi")) 
	return 1.; 
    
    return 0.;
}


void PDalitzDecay::sampleMD(const double &ecm, const int &id, 
			    double &m, const double &m1) {
    // Mass sampling algorithm in case of Dalitz decay to a dilepton 
    // and the a second particle whose mass is taken to be fixed.
    // Arguments: parent cm energy, parent id, dilepton mass 
    //            (to be returned), other product mass (fixed)
    //
    // sampling does not work for eta->gmumu  ===> adjust the bounding function
    // or find better method! 


    if (flatMD) {    // for test purposes sample a flat mass distribution
	m = ml + (ecm-ml-m1)*PUtils::sampleFlat();
	return;
    }

    //because there is the eta->gmumu bug and I have no idea how
    //the Kagarlis sampling work, I try the ROOT GetRandom()
    //IF, 21.1.2009
    if (id == eta_prime) {
	m = GetRandom();
	return;
    }

    //another bug in w -> pi mumu (rep by E.Krebs, 13.5.2013)
    if (id == w && sw==1) {
	m = GetRandom();
	return;
    }


    int stored_rejection_flag = rejection_flag;

    if (rejection_flag == 2) //omega
	if (ecm <= mass_parent)
	    // w with mass < pole: go back to flag 0
	    rejection_flag = 0;

    double mx = ecm-m1;                  // dilepton mass ceiling
    double p1 = dGdM(id, ml, ecm);      // absolute peak for m=2me
    double b = ml, dw = ecm-mass_parent, area;      // rejection-method parameters
    double p2 = -1, mi, a, y, bw = -1, a1 = -1, a2, f;


    if (rejection_flag == 0 && sw == 1) 
	p1 = dGdM(id,ml+0.1,ecm);  // for mumu decay add a bit to get peak

    if (rejection_flag == 1) b /= ecm;             // adjust parameter for eta'

    if (rejection_flag == 2 && ecm > mass_parent) {  // parameter area for w with ecm>pole mass
	mi = mass_parent - m1;       // cusp positioned here if omega with mass > pole
	p2 = (ecm+ml-mi)*dGdM(id,mi,ecm);// value of the local peak
	a1 = (p1+p2)*log(mi/ml);         // area up to m = m_w0 - m_pi0
	bw = p1/mi + p2/(dw+ml);
	a2 = 0.5*bw*dw;                  // area past mass_parent, containing the cusp
	area = a1 + a2;                  // total area under the test function
    } else {                             // area for all the other cases
	area = log(mx/ml);
	if (rejection_flag == 1) area *= 2.;         // adjust if eta'
    }
  
    //__________________________________________________________________
    // The rejection method is used for mass sampling:
    // The test function must be integrable, invertible, and bounding the actual
    // distribution function from above over the range of the variable (mass);
    // see e.g. Ref 6.
  
    do {                               // enter the rejection-method loop

	a = area * PUtils::sampleFlat(); // sample a test area 0 < a(m) < total area

	if (rejection_flag != 2) {
	    m = b * exp(a);
	    if (rejection_flag == 1) m *= (ecm+ml)/(1.+m);
	    f = p1/m;
	    if (rejection_flag == 1) f += p1/(ecm+ml-m);
	} else if (a > a1) {
	    m = 2.*mx*(area-a)/bw;
	    m = mx - sqrt(m);
	    f = -bw*(m-mx)/dw;
	} else {
	    m = ml*exp(a/(p1+p2));
	    f = p1/m+p2/(mx+ml-m);
	}

	y = dGdM(id, m, ecm);          // y(m) is the actual distribution function
    
    } while (f*PUtils::sampleFlat() > y);// compare with f(m) and accept or reject
  

    rejection_flag = stored_rejection_flag;
    if (f < y) m = ml; //method fails, return minimum mass
};

double PDalitzDecay:: PhotonBR(const int &id) {
  // Looks up (from PBR[]) the static BR for a meson with a Dalitz decay
  // channel X + dilepton to the corresponding X + (real photon) channel.
  // (Look at the comments in dG/dM to see why this is needed.)
    
    int i, np, i1, i2;
    
    int x = 0;   // this is the 2nd product (non dilepton) id
    if (makeStaticData()->IsParticle(id,"pi0")||
	makeStaticData()->IsParticle(id,"eta")||
	makeStaticData()->IsParticle(id,"eta'")) 
	x = makeStaticData()->GetParticleID("g");
    else if (makeStaticData()->IsParticle(id,"D0") || 
	     makeStaticData()->IsParticle(id,"Lambda") || 
	     makeStaticData()->IsParticle(id,"NS110") || 
	     makeStaticData()->IsParticle(id,"ND130")) 
	x = makeStaticData()->GetParticleID("n");
    else if (makeStaticData()->IsParticle(id,"D+")   ||
	     makeStaticData()->IsParticle(id,"NP11+") ||
	     makeStaticData()->IsParticle(id,"ND13+") ||
	     makeStaticData()->IsParticle(id,"NS11+")) 
	x = makeStaticData()->GetParticleID("p");
    else if (makeStaticData()->IsParticle(id,"w")||
	     makeStaticData()->IsParticle(id,"phi")) 
	x = makeStaticData()->GetParticleID("pi0");
    Int_t tid[11];

    Int_t *didx;
    Int_t listkey = -1;
    int key = makeDataBase()->GetEntryInt("pid", id);
    while (makeDataBase()->MakeListIterator
	   (key, "pnmodes", "link", &listkey)) {	
	makeDataBase()->GetParamInt(listkey, "didx", &didx); //small workaround -> should work on keys
	tid[0] = 10;
	makeStaticData()->GetDecayModeByKey(listkey, tid); // retrieve current mode info
	int pos = makeStaticData()->GetDecayIdxByKey(listkey);
	
	for (i=0; i<tid[0]; ++i) {            // loop over the decay modes
	    np = tid[0];                    // number of products in current mode
	    if (np == 2) {                   // check 2-product decays only
		i1 = tid[1];                  // pids of products
		i2 = tid[2];
		if ((makeStaticData()->IsParticle(i1,"g")
		     &&i2 == x)||    // good decay mode
		    (makeStaticData()->IsParticle(i2,"g")
		     &&i1 == x)) return makeStaticData()->GetDecayBR(pos);
	    };
	}
    }
    
    return 0.;                       // no such mode
};

void PDalitzDecay::Print(const Option_t *) const {  
    //Debug info
    BasePrint();
    if (useQED) 
	cout << "Uses QED form factor" << endl;
    else 
	cout << "Uses VMD form factor" << endl;
}
 PDalitzDecay.cc:1
 PDalitzDecay.cc:2
 PDalitzDecay.cc:3
 PDalitzDecay.cc:4
 PDalitzDecay.cc:5
 PDalitzDecay.cc:6
 PDalitzDecay.cc:7
 PDalitzDecay.cc:8
 PDalitzDecay.cc:9
 PDalitzDecay.cc:10
 PDalitzDecay.cc:11
 PDalitzDecay.cc:12
 PDalitzDecay.cc:13
 PDalitzDecay.cc:14
 PDalitzDecay.cc:15
 PDalitzDecay.cc:16
 PDalitzDecay.cc:17
 PDalitzDecay.cc:18
 PDalitzDecay.cc:19
 PDalitzDecay.cc:20
 PDalitzDecay.cc:21
 PDalitzDecay.cc:22
 PDalitzDecay.cc:23
 PDalitzDecay.cc:24
 PDalitzDecay.cc:25
 PDalitzDecay.cc:26
 PDalitzDecay.cc:27
 PDalitzDecay.cc:28
 PDalitzDecay.cc:29
 PDalitzDecay.cc:30
 PDalitzDecay.cc:31
 PDalitzDecay.cc:32
 PDalitzDecay.cc:33
 PDalitzDecay.cc:34
 PDalitzDecay.cc:35
 PDalitzDecay.cc:36
 PDalitzDecay.cc:37
 PDalitzDecay.cc:38
 PDalitzDecay.cc:39
 PDalitzDecay.cc:40
 PDalitzDecay.cc:41
 PDalitzDecay.cc:42
 PDalitzDecay.cc:43
 PDalitzDecay.cc:44
 PDalitzDecay.cc:45
 PDalitzDecay.cc:46
 PDalitzDecay.cc:47
 PDalitzDecay.cc:48
 PDalitzDecay.cc:49
 PDalitzDecay.cc:50
 PDalitzDecay.cc:51
 PDalitzDecay.cc:52
 PDalitzDecay.cc:53
 PDalitzDecay.cc:54
 PDalitzDecay.cc:55
 PDalitzDecay.cc:56
 PDalitzDecay.cc:57
 PDalitzDecay.cc:58
 PDalitzDecay.cc:59
 PDalitzDecay.cc:60
 PDalitzDecay.cc:61
 PDalitzDecay.cc:62
 PDalitzDecay.cc:63
 PDalitzDecay.cc:64
 PDalitzDecay.cc:65
 PDalitzDecay.cc:66
 PDalitzDecay.cc:67
 PDalitzDecay.cc:68
 PDalitzDecay.cc:69
 PDalitzDecay.cc:70
 PDalitzDecay.cc:71
 PDalitzDecay.cc:72
 PDalitzDecay.cc:73
 PDalitzDecay.cc:74
 PDalitzDecay.cc:75
 PDalitzDecay.cc:76
 PDalitzDecay.cc:77
 PDalitzDecay.cc:78
 PDalitzDecay.cc:79
 PDalitzDecay.cc:80
 PDalitzDecay.cc:81
 PDalitzDecay.cc:82
 PDalitzDecay.cc:83
 PDalitzDecay.cc:84
 PDalitzDecay.cc:85
 PDalitzDecay.cc:86
 PDalitzDecay.cc:87
 PDalitzDecay.cc:88
 PDalitzDecay.cc:89
 PDalitzDecay.cc:90
 PDalitzDecay.cc:91
 PDalitzDecay.cc:92
 PDalitzDecay.cc:93
 PDalitzDecay.cc:94
 PDalitzDecay.cc:95
 PDalitzDecay.cc:96
 PDalitzDecay.cc:97
 PDalitzDecay.cc:98
 PDalitzDecay.cc:99
 PDalitzDecay.cc:100
 PDalitzDecay.cc:101
 PDalitzDecay.cc:102
 PDalitzDecay.cc:103
 PDalitzDecay.cc:104
 PDalitzDecay.cc:105
 PDalitzDecay.cc:106
 PDalitzDecay.cc:107
 PDalitzDecay.cc:108
 PDalitzDecay.cc:109
 PDalitzDecay.cc:110
 PDalitzDecay.cc:111
 PDalitzDecay.cc:112
 PDalitzDecay.cc:113
 PDalitzDecay.cc:114
 PDalitzDecay.cc:115
 PDalitzDecay.cc:116
 PDalitzDecay.cc:117
 PDalitzDecay.cc:118
 PDalitzDecay.cc:119
 PDalitzDecay.cc:120
 PDalitzDecay.cc:121
 PDalitzDecay.cc:122
 PDalitzDecay.cc:123
 PDalitzDecay.cc:124
 PDalitzDecay.cc:125
 PDalitzDecay.cc:126
 PDalitzDecay.cc:127
 PDalitzDecay.cc:128
 PDalitzDecay.cc:129
 PDalitzDecay.cc:130
 PDalitzDecay.cc:131
 PDalitzDecay.cc:132
 PDalitzDecay.cc:133
 PDalitzDecay.cc:134
 PDalitzDecay.cc:135
 PDalitzDecay.cc:136
 PDalitzDecay.cc:137
 PDalitzDecay.cc:138
 PDalitzDecay.cc:139
 PDalitzDecay.cc:140
 PDalitzDecay.cc:141
 PDalitzDecay.cc:142
 PDalitzDecay.cc:143
 PDalitzDecay.cc:144
 PDalitzDecay.cc:145
 PDalitzDecay.cc:146
 PDalitzDecay.cc:147
 PDalitzDecay.cc:148
 PDalitzDecay.cc:149
 PDalitzDecay.cc:150
 PDalitzDecay.cc:151
 PDalitzDecay.cc:152
 PDalitzDecay.cc:153
 PDalitzDecay.cc:154
 PDalitzDecay.cc:155
 PDalitzDecay.cc:156
 PDalitzDecay.cc:157
 PDalitzDecay.cc:158
 PDalitzDecay.cc:159
 PDalitzDecay.cc:160
 PDalitzDecay.cc:161
 PDalitzDecay.cc:162
 PDalitzDecay.cc:163
 PDalitzDecay.cc:164
 PDalitzDecay.cc:165
 PDalitzDecay.cc:166
 PDalitzDecay.cc:167
 PDalitzDecay.cc:168
 PDalitzDecay.cc:169
 PDalitzDecay.cc:170
 PDalitzDecay.cc:171
 PDalitzDecay.cc:172
 PDalitzDecay.cc:173
 PDalitzDecay.cc:174
 PDalitzDecay.cc:175
 PDalitzDecay.cc:176
 PDalitzDecay.cc:177
 PDalitzDecay.cc:178
 PDalitzDecay.cc:179
 PDalitzDecay.cc:180
 PDalitzDecay.cc:181
 PDalitzDecay.cc:182
 PDalitzDecay.cc:183
 PDalitzDecay.cc:184
 PDalitzDecay.cc:185
 PDalitzDecay.cc:186
 PDalitzDecay.cc:187
 PDalitzDecay.cc:188
 PDalitzDecay.cc:189
 PDalitzDecay.cc:190
 PDalitzDecay.cc:191
 PDalitzDecay.cc:192
 PDalitzDecay.cc:193
 PDalitzDecay.cc:194
 PDalitzDecay.cc:195
 PDalitzDecay.cc:196
 PDalitzDecay.cc:197
 PDalitzDecay.cc:198
 PDalitzDecay.cc:199
 PDalitzDecay.cc:200
 PDalitzDecay.cc:201
 PDalitzDecay.cc:202
 PDalitzDecay.cc:203
 PDalitzDecay.cc:204
 PDalitzDecay.cc:205
 PDalitzDecay.cc:206
 PDalitzDecay.cc:207
 PDalitzDecay.cc:208
 PDalitzDecay.cc:209
 PDalitzDecay.cc:210
 PDalitzDecay.cc:211
 PDalitzDecay.cc:212
 PDalitzDecay.cc:213
 PDalitzDecay.cc:214
 PDalitzDecay.cc:215
 PDalitzDecay.cc:216
 PDalitzDecay.cc:217
 PDalitzDecay.cc:218
 PDalitzDecay.cc:219
 PDalitzDecay.cc:220
 PDalitzDecay.cc:221
 PDalitzDecay.cc:222
 PDalitzDecay.cc:223
 PDalitzDecay.cc:224
 PDalitzDecay.cc:225
 PDalitzDecay.cc:226
 PDalitzDecay.cc:227
 PDalitzDecay.cc:228
 PDalitzDecay.cc:229
 PDalitzDecay.cc:230
 PDalitzDecay.cc:231
 PDalitzDecay.cc:232
 PDalitzDecay.cc:233
 PDalitzDecay.cc:234
 PDalitzDecay.cc:235
 PDalitzDecay.cc:236
 PDalitzDecay.cc:237
 PDalitzDecay.cc:238
 PDalitzDecay.cc:239
 PDalitzDecay.cc:240
 PDalitzDecay.cc:241
 PDalitzDecay.cc:242
 PDalitzDecay.cc:243
 PDalitzDecay.cc:244
 PDalitzDecay.cc:245
 PDalitzDecay.cc:246
 PDalitzDecay.cc:247
 PDalitzDecay.cc:248
 PDalitzDecay.cc:249
 PDalitzDecay.cc:250
 PDalitzDecay.cc:251
 PDalitzDecay.cc:252
 PDalitzDecay.cc:253
 PDalitzDecay.cc:254
 PDalitzDecay.cc:255
 PDalitzDecay.cc:256
 PDalitzDecay.cc:257
 PDalitzDecay.cc:258
 PDalitzDecay.cc:259
 PDalitzDecay.cc:260
 PDalitzDecay.cc:261
 PDalitzDecay.cc:262
 PDalitzDecay.cc:263
 PDalitzDecay.cc:264
 PDalitzDecay.cc:265
 PDalitzDecay.cc:266
 PDalitzDecay.cc:267
 PDalitzDecay.cc:268
 PDalitzDecay.cc:269
 PDalitzDecay.cc:270
 PDalitzDecay.cc:271
 PDalitzDecay.cc:272
 PDalitzDecay.cc:273
 PDalitzDecay.cc:274
 PDalitzDecay.cc:275
 PDalitzDecay.cc:276
 PDalitzDecay.cc:277
 PDalitzDecay.cc:278
 PDalitzDecay.cc:279
 PDalitzDecay.cc:280
 PDalitzDecay.cc:281
 PDalitzDecay.cc:282
 PDalitzDecay.cc:283
 PDalitzDecay.cc:284
 PDalitzDecay.cc:285
 PDalitzDecay.cc:286
 PDalitzDecay.cc:287
 PDalitzDecay.cc:288
 PDalitzDecay.cc:289
 PDalitzDecay.cc:290
 PDalitzDecay.cc:291
 PDalitzDecay.cc:292
 PDalitzDecay.cc:293
 PDalitzDecay.cc:294
 PDalitzDecay.cc:295
 PDalitzDecay.cc:296
 PDalitzDecay.cc:297
 PDalitzDecay.cc:298
 PDalitzDecay.cc:299
 PDalitzDecay.cc:300
 PDalitzDecay.cc:301
 PDalitzDecay.cc:302
 PDalitzDecay.cc:303
 PDalitzDecay.cc:304
 PDalitzDecay.cc:305
 PDalitzDecay.cc:306
 PDalitzDecay.cc:307
 PDalitzDecay.cc:308
 PDalitzDecay.cc:309
 PDalitzDecay.cc:310
 PDalitzDecay.cc:311
 PDalitzDecay.cc:312
 PDalitzDecay.cc:313
 PDalitzDecay.cc:314
 PDalitzDecay.cc:315
 PDalitzDecay.cc:316
 PDalitzDecay.cc:317
 PDalitzDecay.cc:318
 PDalitzDecay.cc:319
 PDalitzDecay.cc:320
 PDalitzDecay.cc:321
 PDalitzDecay.cc:322
 PDalitzDecay.cc:323
 PDalitzDecay.cc:324
 PDalitzDecay.cc:325
 PDalitzDecay.cc:326
 PDalitzDecay.cc:327
 PDalitzDecay.cc:328
 PDalitzDecay.cc:329
 PDalitzDecay.cc:330
 PDalitzDecay.cc:331
 PDalitzDecay.cc:332
 PDalitzDecay.cc:333
 PDalitzDecay.cc:334
 PDalitzDecay.cc:335
 PDalitzDecay.cc:336
 PDalitzDecay.cc:337
 PDalitzDecay.cc:338
 PDalitzDecay.cc:339
 PDalitzDecay.cc:340
 PDalitzDecay.cc:341
 PDalitzDecay.cc:342
 PDalitzDecay.cc:343
 PDalitzDecay.cc:344
 PDalitzDecay.cc:345
 PDalitzDecay.cc:346
 PDalitzDecay.cc:347
 PDalitzDecay.cc:348
 PDalitzDecay.cc:349
 PDalitzDecay.cc:350
 PDalitzDecay.cc:351
 PDalitzDecay.cc:352
 PDalitzDecay.cc:353
 PDalitzDecay.cc:354
 PDalitzDecay.cc:355
 PDalitzDecay.cc:356
 PDalitzDecay.cc:357
 PDalitzDecay.cc:358
 PDalitzDecay.cc:359
 PDalitzDecay.cc:360
 PDalitzDecay.cc:361
 PDalitzDecay.cc:362
 PDalitzDecay.cc:363
 PDalitzDecay.cc:364
 PDalitzDecay.cc:365
 PDalitzDecay.cc:366
 PDalitzDecay.cc:367
 PDalitzDecay.cc:368
 PDalitzDecay.cc:369
 PDalitzDecay.cc:370
 PDalitzDecay.cc:371
 PDalitzDecay.cc:372
 PDalitzDecay.cc:373
 PDalitzDecay.cc:374
 PDalitzDecay.cc:375
 PDalitzDecay.cc:376
 PDalitzDecay.cc:377
 PDalitzDecay.cc:378
 PDalitzDecay.cc:379
 PDalitzDecay.cc:380
 PDalitzDecay.cc:381
 PDalitzDecay.cc:382
 PDalitzDecay.cc:383
 PDalitzDecay.cc:384
 PDalitzDecay.cc:385
 PDalitzDecay.cc:386
 PDalitzDecay.cc:387
 PDalitzDecay.cc:388
 PDalitzDecay.cc:389
 PDalitzDecay.cc:390
 PDalitzDecay.cc:391
 PDalitzDecay.cc:392
 PDalitzDecay.cc:393
 PDalitzDecay.cc:394
 PDalitzDecay.cc:395
 PDalitzDecay.cc:396
 PDalitzDecay.cc:397
 PDalitzDecay.cc:398
 PDalitzDecay.cc:399
 PDalitzDecay.cc:400
 PDalitzDecay.cc:401
 PDalitzDecay.cc:402
 PDalitzDecay.cc:403
 PDalitzDecay.cc:404
 PDalitzDecay.cc:405
 PDalitzDecay.cc:406
 PDalitzDecay.cc:407
 PDalitzDecay.cc:408
 PDalitzDecay.cc:409
 PDalitzDecay.cc:410
 PDalitzDecay.cc:411
 PDalitzDecay.cc:412
 PDalitzDecay.cc:413
 PDalitzDecay.cc:414
 PDalitzDecay.cc:415
 PDalitzDecay.cc:416
 PDalitzDecay.cc:417
 PDalitzDecay.cc:418
 PDalitzDecay.cc:419
 PDalitzDecay.cc:420
 PDalitzDecay.cc:421
 PDalitzDecay.cc:422
 PDalitzDecay.cc:423
 PDalitzDecay.cc:424
 PDalitzDecay.cc:425
 PDalitzDecay.cc:426
 PDalitzDecay.cc:427
 PDalitzDecay.cc:428
 PDalitzDecay.cc:429
 PDalitzDecay.cc:430
 PDalitzDecay.cc:431
 PDalitzDecay.cc:432
 PDalitzDecay.cc:433
 PDalitzDecay.cc:434
 PDalitzDecay.cc:435
 PDalitzDecay.cc:436
 PDalitzDecay.cc:437
 PDalitzDecay.cc:438
 PDalitzDecay.cc:439
 PDalitzDecay.cc:440
 PDalitzDecay.cc:441
 PDalitzDecay.cc:442
 PDalitzDecay.cc:443
 PDalitzDecay.cc:444
 PDalitzDecay.cc:445
 PDalitzDecay.cc:446
 PDalitzDecay.cc:447
 PDalitzDecay.cc:448
 PDalitzDecay.cc:449
 PDalitzDecay.cc:450
 PDalitzDecay.cc:451
 PDalitzDecay.cc:452
 PDalitzDecay.cc:453
 PDalitzDecay.cc:454
 PDalitzDecay.cc:455
 PDalitzDecay.cc:456
 PDalitzDecay.cc:457
 PDalitzDecay.cc:458
 PDalitzDecay.cc:459
 PDalitzDecay.cc:460
 PDalitzDecay.cc:461
 PDalitzDecay.cc:462
 PDalitzDecay.cc:463
 PDalitzDecay.cc:464
 PDalitzDecay.cc:465
 PDalitzDecay.cc:466
 PDalitzDecay.cc:467
 PDalitzDecay.cc:468
 PDalitzDecay.cc:469
 PDalitzDecay.cc:470
 PDalitzDecay.cc:471
 PDalitzDecay.cc:472
 PDalitzDecay.cc:473
 PDalitzDecay.cc:474
 PDalitzDecay.cc:475
 PDalitzDecay.cc:476
 PDalitzDecay.cc:477
 PDalitzDecay.cc:478
 PDalitzDecay.cc:479
 PDalitzDecay.cc:480
 PDalitzDecay.cc:481
 PDalitzDecay.cc:482
 PDalitzDecay.cc:483
 PDalitzDecay.cc:484
 PDalitzDecay.cc:485
 PDalitzDecay.cc:486
 PDalitzDecay.cc:487
 PDalitzDecay.cc:488
 PDalitzDecay.cc:489
 PDalitzDecay.cc:490
 PDalitzDecay.cc:491
 PDalitzDecay.cc:492
 PDalitzDecay.cc:493
 PDalitzDecay.cc:494
 PDalitzDecay.cc:495
 PDalitzDecay.cc:496
 PDalitzDecay.cc:497
 PDalitzDecay.cc:498
 PDalitzDecay.cc:499
 PDalitzDecay.cc:500
 PDalitzDecay.cc:501
 PDalitzDecay.cc:502
 PDalitzDecay.cc:503
 PDalitzDecay.cc:504
 PDalitzDecay.cc:505
 PDalitzDecay.cc:506
 PDalitzDecay.cc:507
 PDalitzDecay.cc:508
 PDalitzDecay.cc:509
 PDalitzDecay.cc:510
 PDalitzDecay.cc:511
 PDalitzDecay.cc:512
 PDalitzDecay.cc:513
 PDalitzDecay.cc:514
 PDalitzDecay.cc:515
 PDalitzDecay.cc:516
 PDalitzDecay.cc:517
 PDalitzDecay.cc:518
 PDalitzDecay.cc:519
 PDalitzDecay.cc:520
 PDalitzDecay.cc:521
 PDalitzDecay.cc:522
 PDalitzDecay.cc:523
 PDalitzDecay.cc:524
 PDalitzDecay.cc:525
 PDalitzDecay.cc:526
 PDalitzDecay.cc:527
 PDalitzDecay.cc:528
 PDalitzDecay.cc:529
 PDalitzDecay.cc:530
 PDalitzDecay.cc:531
 PDalitzDecay.cc:532
 PDalitzDecay.cc:533
 PDalitzDecay.cc:534
 PDalitzDecay.cc:535
 PDalitzDecay.cc:536
 PDalitzDecay.cc:537
 PDalitzDecay.cc:538
 PDalitzDecay.cc:539
 PDalitzDecay.cc:540
 PDalitzDecay.cc:541
 PDalitzDecay.cc:542
 PDalitzDecay.cc:543
 PDalitzDecay.cc:544
 PDalitzDecay.cc:545
 PDalitzDecay.cc:546
 PDalitzDecay.cc:547
 PDalitzDecay.cc:548
 PDalitzDecay.cc:549
 PDalitzDecay.cc:550
 PDalitzDecay.cc:551
 PDalitzDecay.cc:552
 PDalitzDecay.cc:553
 PDalitzDecay.cc:554
 PDalitzDecay.cc:555
 PDalitzDecay.cc:556
 PDalitzDecay.cc:557
 PDalitzDecay.cc:558
 PDalitzDecay.cc:559
 PDalitzDecay.cc:560
 PDalitzDecay.cc:561
 PDalitzDecay.cc:562
 PDalitzDecay.cc:563
 PDalitzDecay.cc:564
 PDalitzDecay.cc:565
 PDalitzDecay.cc:566
 PDalitzDecay.cc:567
 PDalitzDecay.cc:568
 PDalitzDecay.cc:569
 PDalitzDecay.cc:570
 PDalitzDecay.cc:571
 PDalitzDecay.cc:572
 PDalitzDecay.cc:573
 PDalitzDecay.cc:574
 PDalitzDecay.cc:575
 PDalitzDecay.cc:576
 PDalitzDecay.cc:577
 PDalitzDecay.cc:578
 PDalitzDecay.cc:579
 PDalitzDecay.cc:580
 PDalitzDecay.cc:581
 PDalitzDecay.cc:582
 PDalitzDecay.cc:583
 PDalitzDecay.cc:584
 PDalitzDecay.cc:585
 PDalitzDecay.cc:586
 PDalitzDecay.cc:587
 PDalitzDecay.cc:588
 PDalitzDecay.cc:589
 PDalitzDecay.cc:590
 PDalitzDecay.cc:591
 PDalitzDecay.cc:592
 PDalitzDecay.cc:593
 PDalitzDecay.cc:594
 PDalitzDecay.cc:595
 PDalitzDecay.cc:596
 PDalitzDecay.cc:597
 PDalitzDecay.cc:598
 PDalitzDecay.cc:599
 PDalitzDecay.cc:600
 PDalitzDecay.cc:601
 PDalitzDecay.cc:602
 PDalitzDecay.cc:603