Greetings
I would like to implement several logic statements into a distribution using PAnyDistrubution.
I tried to model this by mimicking the example macro demo_PAnyDistribution in the macros directory.
TH1F * cache = new TH1F ("cache","Rho0 t cache",400,-4.0,0.0);
decay->AddEquation(cache,"beam = _parent->GetBeam(); beam->Boost(_parent) ; t1 = (beam - [rho0])->Mag2(); _x = t1;");
decay->AddEquation("beam2 = _parent->GetBeam(); beam2->Boost(_parent); if (beam2 < 4.6) _f = exp( 6.9*t1 ); if (beam2 > 4.6) _f = exp( 8.9*t1 );");
It seems I do not understand, because PLUTO will always execute the first "IF" statement regardless of the beam energy.
If this something I would have to use a 2D histogram for? A 2D histogram seems overkill for a project like this.
Thanks
[Updated on: Tue, 28 May 2013 18:38]
Report message to a moderator