SLAC PEP-II
BABAR
SLAC<->RAL
Babar logo
Workbook HEPIC Databases PDG HEP preprints
Organization Detector Computing Physics Documentation
Personnel Glossary Sitemap Search Hypernews
Unwrap page!
Wkbk. Search
Wkbk. Sitemap
Introduction
Non SLAC
HOWTO's
Introduction
Logging In
QuickTour
Detector
Info Resources
Software Infrastructure
CM2 Introduction
Unix
OO
SRT
Objectivity
Event Store
Framework
Beta
Modifying Code
Writing and Editing
Compiling
Debugging
Analysis
Framework II
Analysis
Find Data
Batch Processing
PAW
PAW II
ROOT I
ROOT II
ROOT III
Advanced Infrastructure
New Releases
Workdir
Main Packages
Event Displays
Gen/Sim/Reco
Contributing Software
SRT and CVS
Coding
Advanced Topics
Make CM2 Ntuples
New Packages
New Packages 2
Persistent Classes
Java
Site Installation
Check this page for HTML 4.01 Transitional compliance with the
W3C Validator
(More checks...)

Single Candidate Information Available in the Micro Database

This page contains tables documenting many of the variables accessible through the micro portion of the Analysis Database.

Contents:

Reco vs. "Packed Micro" comparison plots

These plots are designed to show the effect that packing. They show the output of RECO compared to the packed value stored in MICRO. The variable calculated with from the RECO begins with a "t" (for transient), while the variable value stored in the packed MICRO begins with a "p" (for persistent). Note that not all variables can be calculated from RECO directly, so not all plots have meaningful transient data.

Needed Includes and Pointers

Initialize the following pointers in your analysis code.
#include "BetaMicroAdapter/BtaMicroAdapter.hh"
#include "BetaMicroAdapter/BtaCalQual.hh"
#include "BetaMicroAdapter/BtaPidQual.hh"
#include "BetaMicroAdapter/BtaTrkQual.hh"
#include "BetaMicroAdapter/BtaPidInfo.hh"
#include "BetaMicroAdapter/BtaIfrQual.hh"
BtaCandidate* aBtaCandidate;
const BtaTrkQual* TrkQual = aBtaCandidate->getMicroAdapter()->getTrkQual();
const BtaCalQual* CalQual = aBtaCandidate->getMicroAdapter()->getCalQual();
const BtaPidQual* PidQual = aBtaCandidate->getMicroAdapter()->getPidQual();
const BtaPidInfo* PidInfo = aBtaCandidate->getMicroAdapter()->getPidInfo();
const BtaIfrQual* IfrQual = aBtaCandidate->getMicroAdapter()->getIfrQual();
As you are iterating over a list of type BtaCandidate, a pointer will return NULL if that information does not exist for that candidate, and you will not be able to access any variables that use that pointer. As examples, CalQual=0 if there is no energy deposit in the calorimeter; TrkQual=0 if there are no SVT or DCH hits.

Tracking Information

Variable Type Range Packing Size in DB Description Reco vs. "Packed Micro" Plots
Description at top
TrkQual->nDof() Int 0->255 Integer 1 byte number of degrees of freedom of the track-fit Available
TrkQual->prob() Float 0->1 N/A N/A Probability of the chi-squared of the track fit.  Not stored directly in the database - calculated from other, stored quantities. Not Available Yet!
TrkQual->chi2() Float 0->1000 Logarithmic 2 bytes Chi-squared of the track fit Available
TrkQual->trackLength() Float 0->100 Logarithmic 1 byte Track length (cm) from the first to the last hit Available
TrkQual->startFoundRange() Float 0->100 Logarithmic 1 byte Track length (cm) from origin to the first hit Available
TrkQual->nSvtHits() Int 0->15 Integer 4 bits The number of z and phi hits in the SVT that are on this candidate's track. Each of the SVT's 5 layers provides a both z and phi information. It is possible to have more than 10 hits (5 phi + 5z) due to low transverse-momentum charged tracks which can curl up in the detector. FYI, a track with Pt=0.1 GeV will make it to the outer edge of the SVT-DCH interface. Available
TrkQual->SvtPattern() Int 0->1023 Integer 10 bits The 10 bits of the word correspond to whether one of the 10 views of the SVT registered a hit for this candidate:
Layer 5 z-view = Most Significant Bit
Layer 4 z-view
Layer 3 z-view
Layer 2 z-view
Layer 1 z-view
Layer 5 r/phi-view
Layer 4 r/phi-view
Layer 3 r/phi-view
Layer 2 r/phi-view
Layer 1 r-phi-view = Least Significant Bit
TrkQual->SvtOn(int layer) Bool True/False Integer 1 bit each for 10 layers True if this candidate has a SVT hit on track for the given layer.  Each of the 5 SVT layers contains both r and phi info:
Layers 0->4 represent r-phi hits on the 5 layers, with 0 denoting the innermost layer.
Layers 5->9 represent z hits on the 5 layers, with 5 denoting the innermost layer.
Layer 0, 1, 2, 3, 4, 5, 6, 7, 8
TrkQual->firstDchHit() Int 0->255 Integer 1 byte Innermost layer of the DCH registering a hit associated with this charged candidate's track. There are 40 layers in the Drift Chamber. Available
TrkQual->lastDchHit() Int 0->255 Integer 1 byte Outermost layer of the DCH registering a hit associated with this candidate's track. There are 40 layers in the Drift Chamber. Available
TrkQual->nDchHits() Int 0->255 Integer 1 byte Number of DCH layers registering hits associated with this candidate's track. There are 40 layers in the Drift Chamber. Due to low transverse-momentum tracks which can curl up in the detector, this number can be greater than 40. Available
TrkQual->pidHypo() Int 0->7 Integer 3 bits Particle Hypothesis used while fitting the track (i.e. what mass was used). The mapping is as follows:
0= electron
1= muon
2= pion
3= kaon
4= proton
Not Available Yet!
TrkQual->fitStatus() Bool True/False Integer 1 bit Status of the Track Fit Available

Particle Identification Quality

Variable Type Range Packing Size in DB Description Reco vs. "Packed Micro" Plots
Description at top
PidQual->dEdXSvt() Float 0->100 Logarithmic 1 byte dE/dx (arbitrary units) determined from the SVT hits Available
PidQual->nSamplesDeDxSvt() Int 0->255 Integer 1 byte # of samples in the SVT used to calculate dEdXSvt() Available
PidQual->dEdXDch() Float 0->1000 Logarithmic 1 byte dE/dX (arbitrary units) for determined from the Dch hits Available
PidQual->nSamplesDeDxDch() Int 0->255 Integer 1 byte # of samples in the DCH used to calculate dEdXDch() Available
PidQual->deltaDchMomentum() Float -100->0
MeV
Logarithmic 1 byte Candidate's momentum at the entrance of the Drift Chamber minus the momentum at the origin. Available
PidQual->deltaDrcMomentum() Float -100->0
MeV
Logarithmic 1 byte Candidate's momentum at the entrance of the DIRC minus the momentum at the origin. Available
PidQual->drcInBar() Int 0-143 Integer 1 byte ID of the bar the candidate enters first. 0 marks the bar at the top center of the detector. The rest of the bars are numbered in ascending order, following positive right-handed rotation around the electron beam. Note that the number 0 is also stored when the track does not go into the DIRC fiducial volume. Watch for confusion with the actual bar 0! Not Available
PidQual->drcExitBar() Int 0-3 Integer 2 bits ID number of the bar the candidate exits the DIRC from, relative to the bar the candidate first enters.
 0: Exit Bar= Entry Bar
 1: Exit Bar= Entry Bar + 1
 2: Exit Bar= Entry Bar - 1
 3: Greater than 1 bar of displacement
Not Available
PidQual->drcXPos() Double -2 -> +2 cm Integer 6 bits x position where the candidate first enters the "inBar," relative to the center of the bar. (half-width of bar is actually 1.85 cm) Not Available
PidQual->thetaC() Float 0->1 
radian
Flat 2 bytes The opening angle of the Cerenkov ring emitted by the charged candidate. Available
PidQual->thetaCErr() Float 0->1
radian
Logarithmic 2 bytes Error on the opening angle of the Cerenkov ring. Available!
PidQual->ringNPhot() Int 0->255 Integer 1 byte Measured number of signal photons in the Cerenkov ring fit to the detected photons of this charged candidate. Available
PidQual->ringNBkgd() Int 0->255 Integer 1 byte Measured number of background photons in the Cerenkov ring fit to the detected photons of this charged candidate. Available
PidQual->ringNExPhot(const PdtEntry* p) Int 0->255 Integer 1 byte each for the 5 hypothesis (5 bytes total) Number of photons expected to be associated with a ring of this particle's momentum, given Particle ID Entry p. Electron, Muon, Pion, Kaon, Proton
PidQual->phiAtEMC() Float phi of intercept of the track with the EMC Not Available
PidQual->thetaAtEMC() Float theta of intercept of the track with the EMC Not Available

Particle Identification Information

Variable Type Range Packing Size in DB Description Reco vs. "Packed Micro" Plots
Description at top
PidInfo->charge() Int -1->+1 Integer 1 byte Charge of this candidate Not Available Yet!
PidInfo->consistency(const PdtEntry* p, detectors det) Consistency 0->1 Logarithmic 1 byte each for 5 detectors and 5 hypothesis (25 bytes total) Gives the consistency of a single detector's ( PidSystem::ifr,PidSystem::emc,PidSystem::drc,PidSystem::dch, PidSystem::svt) information with a given particle hypothesis, p.
 ElectronMuonPionKaonProton
SVT here here here here here
DCH here here here here here
DRC here here here here here
EMC here here here here here
IFR here here here here here

Calormetric Information

Variable Type Range Packing Size in DB Description Reco vs. "Packed Micro" Plots
Description at top
CalQual->lateralMoment() Float 0->1 Logarithmic 1 byte The lateral moment of the cluster associated with this track. Ratio of 1) to 2):
1) sum of energies of all but the 2 most energetic crystals, weighted by the square of distance to the cluster center
2) Sum of 1) and the energies of the 2 most energetic cystals, which are weighted by r^2. r is the length scale of a crystal, 5 cm.
Available
CalQual->absZernike42() Float 0->1 Logarithmic 1 byte the absolute value of the complex Zernike(4,2) moment. Available
CalQual->absZernike20() Float 0->1 Logarithmic 1 byte the absolute value of the complex Zernike(2,0) moment. Available
CalQual->s1s9() Float 0->1 Logarithmic 1 byte For a cluster, the ratio of the sums of the energies of the central crystal to the central 9 crystals surrounding the centroid. Available
CalQual->s9s25() Float 0->1 Logarithmic 1 byte For a cluster, the ratio of the sums of the energies of the central 9 crystals to the central 25 crystals surrounding the centroid. Available
CalQual->secondMomentTP() Float 0->1 Logarithmic 1 byte The second moment, in theta-phi, of the cluster. Available
CalQual->rawEnergy() Float 0->50 Logarithmic 2 bytes Raw energy measured in EMC (GeV), after digi calibration is applied, but with NO leakage corrections. Not Available
CalQual->ecalEnergy() Float 0->50 Logarithmic 2 bytes energy measured in EMC (GeV), after digi calibration and leakage corrections are applied! Available
CalQual->trkEmcMatchConsistency() Consistency 0->1 Logarithmic 1 byte The consistency of the match between the charged track and the EMC bump, assuming the (conservative) pion hypothesis. Available
CalQual->nBumps() Int 0->15 Integer 4 bits The number of bumps in the calorimeter associated with this candidate. Available
CalQual->nCrystals() Float The number of "hit" crystals for this bump. For a crystal shared between bumps, a splitting algorithm is applied to determine how much of its energy is given to each bump. Thus, it is a float type. Available
CalQual->centroid() HepPoint 0->500
cm
Logarithmic 2 bytes each for 3 directions (6 bytes total) Centroid of the cluster/bump Centroid - X
Centroid - Y
Centroid - Z
CalQual->covMat() HepSymMatrix   Logarithmic 2 bytes each for 4 entries (8 bytes total) 4x4 covariance matrix (E,theta,phi,r) Energy Term
Radial Term
Theta Term
Phi Term
CalQual->neutPid() Int 0->4 Integer 4 bits PID type with which the EMC and IFR quantities have been computed (none = -1,gamma = 0,pi0= 1,K0L= 2, neutron = 3, anti_neutron = 4) Available
CalQual->isOk() Bool True/False returns true if the CalorObject (Cluster or Bump) has no dead or noisy Crystals in it. Also the Object is not in a ROM which is suffering from online dataflow damage or a noisy power supply. Not Available
CalQual->isNoisy() Bool True/False true if at least one crystal in the CalorObject is noisy. Not Available
CalQual->isNearDead() Bool True/False true if at least one crystal in the CalorObject is dead. Not Available
CalQual->isDamaged() Bool True/False true if at least one crystal in the CalorObject is in a Read-Out Module that has online dataflow damage in that event. Not Available
CalQual->isFlickery() Bool True/False true if at least one crystal in the CalorObject is in a Read-Out Module that has power supply noise (flicker). This is worked out by measuring the occupancy of the Read-Out Module in the event, and determining if it is over the following cuts:
Read-Out Module occupancy of digis with energy greater than 1MeV has to be greater than or equal to 50% (barrel) and 100% (end cap) (energetic bhabha's can cause all the crystals in an endcap Read-Out Module to be on)
Not Available
CalQual->maxIsNoisy() Bool True/False true if any of the central 9 crystals of the CalorObject (where center = highest energy crystal) is noisy. Not Available
CalQual->maxIsNearDead() Bool True/False true if any of the central 9 crystals of the CalorObject is dead. Not Available
CalQual->maxIsDamaged() Bool True/False true if any of the central 9 crystals of the CalorObject is in a online dataflow damaged Read-Out Module. Not Available
CalQual->maxIsFlickery() Bool True/False true if any of the central 9 crystals of the CalorObject is in a flickery (flickery defined in description of the isFlickery method, above) the Read-Out Module. Not Available

Muon System Information

Variable Type Range Packing Size in DB Description Reco vs. "Packed Micro" Plots
Description at top
IfrQual->IfrNStrips() Int 0->255 Integer 1 byte Number of "hit" strips associated with this candidate. Not Available Yet!
IfrQual->nStrips(int layer) Int 0->14 Integer 4 bits each for 21 layers and 4 bits for the barrell/endcap division (22x4 bits = 11 bytes)  The number of strips hit in a given IFR layer. Only the range 0->14 is physical.  The one layer which returns 15 is a dummy (not physical) layer used to denote the barrel-endcap interface. Lower numbered layers are in the barrel, while higher numbered layers are in the encap. The total number of strips in both cylindrical RPC layers is stored in layer=0. Not Available Yet!
IfrQual->IfrLayHits() Int 0->20 * see below * see below Number of "hit" layers in the IFR associated with this candidate. If there are hits in both layers of the cylindrical RPC it is counted as one layer in this total. Not Available Yet!
IfrQual->firstHit() Int -1->20 * see below * see below Number of the innermost IFR layer with a hit associated with this candidate. (-1 = cylindrical layer) Not Available Yet!
IfrQual->lastHit() Int -1->20 * see below * see below Number of the outermost IFR layer with a hit associated with this candidate. (-1 = cylindrical layer) Not Available Yet!
IfrQual->hasInner() Bool True/False * see below * see below True when candidate has a hit in the "inner" 2-layer cylindrical layers. Not Available Yet!
IfrQual->hasBarrel() Bool True/False * see below * see below True when candidate has a hit in the "outer" 19-layer barrel region of IFR Not Available Yet!
IfrQual->lastBarrel() Int 0->20 * see below * see below The number of the last barrel layer hit in the IFR. Not Available Yet!
IfrQual->hasFWD() Bool True/False * see below * see below True when candidate has a hit in the 18-layer forward encap of IFR Not Available Yet!
IfrQual->hasBWD() Bool True/False * see below * see below True when candidate has a hit in the 18-layer backward encap of IFR Not Available Yet!
IfrQual->expectedInteractionLengths() Float 0->10 Logarithmic 1 byte The swimmer calculates the number of interaction lengths to the last active RPC chamber along the trajectory of the track. This is a calculation independent of the chambers actually hit. Available
IfrQual->measuredInteractionLengths() Float 0->10 Logarithmic 1 byte Number of interactions lengths through which the candidate's path travels. Dominated by DRC, EMC, and IFR because of their high densisty. Caculated by a "swimmer." Available
IfrQual->interactionLengthsBeforeIron() Float 0->10 Logarithmic 1 byte Number of interactions lengths traversed by a candidate, not including the IFR iron. Again, using a "swimmer." Available
IfrQual->IfrTrkMatchChi2() Float 0->50 Logarithmic 1 byte This is the sum of the squares of the residuals (in both readout perpendicular views) of the measured hit positions w.r.t. the swum track, exrapolated from the DCH. The chi-squared is then normalized to the number of degrees of freedom. Available
IfrQual->IfrEmcMatch() Float 0->1000 Logarithmic 1 byte Numbering indicating the consistency of the IFR hits with the EMC bumps/clusters of this track.. Not Available Yet!
IfrQual->clusterFitChi2() Float For a candidate's IFR cluster, the individual strips for each view are extracted. In each of the 2 perpendicular views, the coordinates of the strips are fit to a second order polynomial. The chi-square of these two fits are then summed to produce this number. This quantity is thus independent of tracking. Not Available Yet!
* The IfrQual quantities marked with this asterisk are not actually stored in the database. They are calculated from IfrQual->nStrips(int layer).

How to find other commonly used quantities

  • To get the consistency(significance level)/likelihood that a candidate is particle XXX:
    
       // get a single detector consistency object
       const Consistency& c1=PidInfo->consistency(Pdt::lookup(PdtPdg::XXX),PidSystem::yyy);
       // to get significance level:
       float myConsistency1= c1.consistency();
       // to get likelihood
       float myLikelihood1= c1.likelihood();
    
    where XXX is the type of particle. For example XXX could be any of (but is not restricted to) the following: e_minus (an electron), mu_minus (a muon), pi_minus (a charged Pion), K_minus (a charged Kaon), p_plus (a proton) and where yyy is the detector. yyy could be any of the following: ifr, emc, drc, dch, svt.

  • To find the candidate trajectory's point of closest approach (in an XY projection), to a particular point, (X,Y,Z):
    
       #include "TrkFitter/TrkPocaXY.hh"
       #include "TrkBase/TrkAbsFit.hh"
       
       TrkPocaXY pocaxy(cand->trkAbsFit()->traj(),0,HepPoint(X,Y,Z));
       HepPoint closestApproach= cand->trkAbsFit()->position(pocaxy.fltl1());
    

    Maintained by Chris Roatcroat@stanford.edu