Finding the B Meson


J/ψs aren’t the only mesons formed in the collider.  In fact, they could be the byproduct of more massive meson’s decay.  Let’s look at the decay of a B meson into a J/ψ plus a kaon.  You’ve already calculated J/ψs, so all you need to do is add another loop, this time to find a kaon track to go with the J/ψ

Try adding the kaon loop and calculating the B mass.  You will need to add more leaves to the tree- follow the example in lines 21-36 to add another structure for the new variable(s) and a branch in which to store them.

The B meson signal will be harder to find than the J/ψ was.  You'll need to run over more data- add more input files by editing the "JpsiLab::JPsiLab" function in JPsiLab.h.  You will also want to implement some cuts in the code to eliminate some background.  A few cuts you might want to consider:

Another way to improve your mass plot is to calculate a "trick mass" equal to the B candidate's mass minus the J/ψ candidate's mass plus 3.096 (the expected J/ψ mass).  This "trick mass" eliminates some of the systematic error in the calculation.

Once you have the B mass, calculate the meson’s vertex point.  Calculating a three-way vertex is much more complicated so we will make use of a vertexing program to save time!  The program is called Lsqfit.  To use Lsqfit, you need to create a fit object and store some parameters of the tracks to be fit.  Here is some example code for using Lsqfit on the J/ψ vertex- if you put this into your program you should find the same vertex coordinates that you calculated algebraically.

LsqFit jpsiFit; //calling LsqFit to find vertex
jpsiFit.push(TRACK_trk_nonbc_phi[trkm], TRACK_trk_nonbc_d0[trkm], sqrt(TRKDET_trkdet_nonbc_sigD02[trkm]), MOM_pt[trkm]); //input parameters for each muon
jpsiFit.push(TRACK_trk_nonbc_phi[trkp], TRACK_trk_nonbc_d0[trkp], sqrt(TRKDET_trkdet_nonbc_sigD02[trkp]), MOM_pt[trkp]);
bool fitStat = jpsiFit.fit(); //apply the fit
Float_t chi2;
if(fitStat){
    chi2 = jpsiFit.chi2();
}else chi2 = 999.; //if fit didn't work, assign a very high chi2
prob = TMath::Prob(chi2, jpsiFit.ndof()); //probability measurement- useful for data cuts
fitx = jpsiFit.x(); //vertex coordinates
fity = jpsiFit.y();
beamdist = jpsiFit.lxy(VERTEX_vtx_svx_beamx, VERTEX_vtx_svx_beamy);  //distance from calculated vtx to beam vtx

The output of Lsqfit, namely the probability of the fit and the beam-to-vertex distance, can also be useful for making further cuts to the mass plot.