'SPECIAL PDFS' RooFit tutorial macro #708
Special decay pdf for B physics with mixing and/or CP violation
Processing /mnt/build/workspace/root-makedoc-v608/rootspi/rdoc/src/v6-08-00-patches/tutorials/roofit/rf708_bphysics.C...
void rf708_bphysics()
{
dt.setBins(40) ;
RooRealVar dw(
"dw",
"delta mistag rate for B0/B0bar",0.1) ;
RooCategory mixState(
"mixState",
"B0/B0bar mixing state") ;
mixState.defineType("mixed",-1) ;
mixState.defineType("unmixed",1) ;
RooCategory tagFlav(
"tagFlav",
"Flavour of the tagged B0") ;
tagFlav.defineType("B0",1) ;
tagFlav.defineType("B0bar",-1) ;
RooBMixDecay bmix(
"bmix",
"decay",dt,mixState,tagFlav,tau,dm,w,dw,truthModel,
RooBMixDecay::DoubleSided) ;
RooPlot* frame1 = dt.frame(
Title(
"B decay distribution with mixing (B0/B0bar)")) ;
data->
plotOn(frame1,
Cut(
"tagFlav==tagFlav::B0")) ;
bmix.plotOn(frame1,
Slice(tagFlav,
"B0")) ;
RooPlot* frame2 = dt.frame(
Title(
"B decay distribution of mixed events (B0/B0bar)")) ;
data->
plotOn(frame2,
Cut(
"mixState==mixState::mixed&&tagFlav==tagFlav::B0")) ;
bmix.plotOn(frame2,
Slice(tagFlav,
"B0"),
Slice(mixState,
"mixed")) ;
RooPlot* frame3 = dt.frame(
Title(
"B decay distribution of unmixed events (B0/B0bar)")) ;
data->
plotOn(frame3,
Cut(
"mixState==mixState::unmixed&&tagFlav==tagFlav::B0")) ;
bmix.plotOn(frame3,
Slice(tagFlav,
"B0"),
Slice(mixState,
"unmixed")) ;
RooRealVar CPeigen(
"CPeigen",
"CP eigen value",-1) ;
RooRealVar absLambda(
"absLambda",
"|lambda|",1,0,2) ;
RooRealVar argLambda(
"absLambda",
"|lambda|",0.7,-1,1) ;
RooRealVar effR(
"effR",
"B0/B0bar reco efficiency ratio",1) ;
RooBCPEffDecay bcp(
"bcp",
"bcp", dt, tagFlav, tau, dm, w, CPeigen, absLambda, argLambda, effR, dw, truthModel,
RooBCPEffDecay::DoubleSided) ;
RooPlot* frame4 = dt.frame(
Title(
"B decay distribution with CPV(|l|=1,Im(l)=0.7) (B0/B0bar)")) ;
data2->
plotOn(frame4,
Cut(
"tagFlav==tagFlav::B0")) ;
bcp.plotOn(frame4,
Slice(tagFlav,
"B0")) ;
absLambda=0.7 ;
RooPlot* frame5 = dt.frame(
Title(
"B decay distribution with CPV(|l|=0.7,Im(l)=0.7) (B0/B0bar)")) ;
data3->
plotOn(frame5,
Cut(
"tagFlav==tagFlav::B0")) ;
bcp.plotOn(frame5,
Slice(tagFlav,
"B0")) ;
RooRealVar DGbG(
"DGbG",
"DGamma/GammaAvg",0.5,-1,1);
RooRealVar Adir(
"Adir",
"-[1-abs(l)**2]/[1+abs(l)**2]",0);
RooRealVar Amix(
"Amix",
"2Im(l)/[1+abs(l)**2]",0.7);
RooRealVar Adel(
"Adel",
"2Re(l)/[1+abs(l)**2]",0.7);
RooBDecay bcpg(
"bcpg",
"bcpg",dt,tau,DG,
RooConst(1),fsinh,fcos,fsin,dm,truthModel,
RooBDecay::DoubleSided);
RooPlot* frame6 = dt.frame(
Title(
"B decay distribution with CPV(Im(l)=0.7,Re(l)=0.7,|l|=1,dG/G=0.5) (B0/B0bar)")) ;
data4->
plotOn(frame6,
Cut(
"tagFlav==tagFlav::B0")) ;
bcpg.plotOn(frame6,
Slice(tagFlav,
"B0")) ;
TCanvas* c =
new TCanvas(
"rf708_bphysics",
"rf708_bphysics",1200,800) ;
}
- Author
- 07/2008 - Wouter Verkerke
Definition in file rf708_bphysics.C.