Pluto v6.3.0
Loading...
Searching...
No Matches
user_eta_3pi_decay.C
Go to the documentation of this file.
1//TITLE Demo using the batch syntax to change the Dalitz plot eta -> 3pi
2
3{
4
5 makeDistributionManager()->Disable("eta_hadronic_decay");
6
8 new PDalitzDistribution("my_hadronic_decay",
9 "Eta matrix element for decay into charged pions");
10 decay->Add("eta, parent");
11 decay->Add("pi0, daughter, primary");
12 decay->Add("pi+, daughter, s1");
13 decay->Add("pi-, daughter, s2");
14 //A "step function"
15 //decay->AddEquation("_f = 1.; m = (_s1 + _primary)->M2() ; echo $m; if m > 0.12; _f = 0.2");
16 decay->AddEquation("_f = 1.; m = (_s1 + _primary)->M2(); if m > 0.12; _f = 0.2");
17 decay->SetMax(1);
19
20 TFile *f = new TFile("histo.root", "RECREATE"); //keep the histogram for the next macro
21 TH2F *hf1 = new TH2F("hf1", "", 100, 0.06, .2, 100, 0.06, .2);
22
23 PReaction my_reaction("2.2", "p", "p", "p p eta [pi+ pi- pi0]", NULL, 1, 0, 0, 0);
24
25 my_reaction.Do(hf1, "_x = ([pi-] + [pi0])->M2() ; _y = ([pi+] + [pi0])->M2()");
26 my_reaction.Print();
27 my_reaction.Loop(10000);
28 hf1->Draw("box");
29
30 //keep the histogram for the next macro:
31 f->cd();
32 hf1->Write();
33
34}
TH1F * hf1
TFile * f
Definition analyze_g12C.C:8
PReaction my_reaction("3.5","p","7Li","p (n) phi [K+ K-] (6Li)","delme")
PReaction my_reaction("2.2", "p", "p", "p p eta [pi+ pi- pi0]", NULL, 1, 0, 0, 0)
PDalitzDistribution * decay
makeDistributionManager() -> Add(decay)