|
FairRoot/PandaRoot
|
#include <Fitter.h>
Public Types | |
| enum | FitStatus { UnFitted = -1, Success = 0, Failed, BadInput, NonConverged } |
Public Member Functions | |
| Fitter (RhoCandidate *bc, RecoTrackStateProvider *extrapolator, int verbosity=0) | |
| constructor from the particle (decay head) More... | |
| Fitter (RhoCandidate *bc, const RhoVector3Err &pv, RecoTrackStateProvider *extrapolator=0, int verbosity=0) | |
| constructor from the particle (decay head) and primary vertex More... | |
| Fitter (RhoCandidate *bc, const RhoLorentzVectorErr &lv, RecoTrackStateProvider *extrapolator, int verbosity=0) | |
| constructor from the particle (decay head) and pbeam More... | |
| Fitter (RhoCandidate *bc, const RhoLorentzVectorErr &lv, const RhoVector3Err &pv, RecoTrackStateProvider *extrapolator=0, int verbosity=0) | |
| constructor from the particle (decay head), pbeam and primary vertex More... | |
| virtual | ~Fitter () |
| destructor More... | |
| void | setMassConstraint (RhoCandidate *cand, bool add=true) |
| Add or remove a mass constraint. More... | |
| void | setMassConstraint (RhoCandidate *cand, double mass) |
| Add a constraint to a mass different from the property table mass. More... | |
| Bool_t | Fit (int maxNumberOfIterations=10, double deltaChisquareConverged=0.01) |
| Add or remove a mass constraintfor a certain ParticleID. More... | |
| Bool_t | FitAll (int maxit=10, double dchiq=0.01) |
| std::string | print () const |
| Print the result of the fit. More... | |
| std::ostream & | fillStream (std::ostream &s) const |
| Print the result of the fit. More... | |
| RhoCandidate * | particle () const |
| The top level particle that is fitted. More... | |
| RhoCandidate * | fitParams (RhoCandidate *p=0) const |
| double | chiSquare () const |
| Total chisquare. More... | |
| int | nDof () const |
| Total number of DOFs. More... | |
| FitStatus | status () const |
| Status of fit. More... | |
| int | nIter () const |
| Number of iterations used by vertex fit. More... | |
| ChiSquare | chiSquare (RhoCandidate *p) const |
| get the chisquare of everything 'downstream' of a particle More... | |
| RhoDoubleErr | decayLengthSum (RhoCandidate *, RhoCandidate *) const |
| bool | updateCand (RhoCandidate *cand) const |
| update a particlular candidate in the tree More... | |
| bool | updateTree (RhoCandidate *cand) const |
| update a particlular candidate in the tree More... | |
| int | errCode () |
| error code More... | |
| void | setVerbose (int i) |
| set the verbosity level (for debugging only) More... | |
| void | SetToleranceZ (double z) |
| DecayChain * | GetDecayChainDirty () |
| RecoTrackStateProvider * | extrapolator () |
| get the extrapolator More... | |
| void | setStateProvider (RecoTrackStateProvider *extrapolator) |
| set the track extrapolator More... | |
| Bool_t | Fit () |
| Bool_t | FitAll () |
| double | Chi2Contribution (const RhoCandidate *) |
| double | GetChi2 () const |
| int | GetNdf () const |
| double | GetProb () const |
| void | SetVerbose (Bool_t v=kTRUE) |
Protected Member Functions | |
| std::string | name (RhoCandidate *cand) const |
| Name of a particle in the decay tree. More... | |
| RhoDoubleErr | decayLengthSum (const ParticleBase &, const ParticleBase &) const |
| DecayChain * | decaychain () |
| FitParams * | fitparams () |
| const DecayChain * | decaychain () const |
| const FitParams * | fitparams () const |
| double | globalChiSquare () const |
| double | add (RhoCandidate *cand) |
| double | remove (RhoCandidate *cand) |
| void | updateIndex () |
| void | fit (int maxNumberOfIterations=10, double deltaChisquareConverged=0.01) |
| Fit the decay tree. More... | |
| void | fitOneStep () |
| Fit just one step. More... | |
| RhoCandidate * | fittedCand (RhoCandidate *cand, RhoCandidate *headoftree) const |
| void | updateCand (const ParticleBase &pb, RhoCandidate *cand) const |
| RhoCandidate & | HeadOfTree () const |
| virtual Bool_t | FitNode (RhoCandidate *b) |
| RhoCandidate * | CopyCand (RhoCandidate *) |
| uppermost particle composite in tree More... | |
| RhoCandidate * | CopyTree (RhoCandidate *) |
| void | InsertChi2 (const RhoCandidate *bc, const double chi2) |
| void | SetDaugthersFromComposite (RhoCandidate *cand) |
| void | FindAndAddFinalStateDaughters (RhoCandidate *cand) |
| void | SetFourMomentumByDaughters (RhoCandidate *composite) |
| void | SetDecayVertex (RhoCandidate *composite, const TVector3 &vtx, const TMatrixD &CovVV) |
Protected Attributes | |
| RecoTrackStateProvider * | m_extrapolator |
| track extrapolator (if needed) More... | |
| Bool_t | fVerbose |
| RhoCandidate * | fHeadOfTree |
| std::vector< RhoCandidate * > | fDaughters |
| double | fChiSquare |
| int | fNDegreesOfFreedom |
Private Member Functions | |
| Fitter () | |
| default constructor is disabled More... | |
| Fitter (const Fitter &) | |
| copy constructor is disabled More... | |
| Fitter & | operator= (const Fitter &) |
| assignement operator is disabled More... | |
Private Attributes | |
| RhoCandidate * | m_particle |
| DecayChain * | m_decaychain |
| FitParams * | m_fitparams |
| FitStatus | m_status |
| int | m_niter |
| int | m_errCode |
| Enumerator | |
|---|---|
| UnFitted | |
| Success | |
| Failed | |
| BadInput | |
| NonConverged | |
Definition at line 59 of file Fitter.h.
| DecayTreeFitter::Fitter::Fitter | ( | RhoCandidate * | bc, |
| RecoTrackStateProvider * | extrapolator, | ||
| int | verbosity = 0 |
||
| ) |
constructor from the particle (decay head)
Definition at line 37 of file Fitter.cxx.
References vtxverbose.
| DecayTreeFitter::Fitter::Fitter | ( | RhoCandidate * | bc, |
| const RhoVector3Err & | pv, | ||
| RecoTrackStateProvider * | extrapolator = 0, |
||
| int | verbosity = 0 |
||
| ) |
constructor from the particle (decay head) and primary vertex
Definition at line 66 of file Fitter.cxx.
References vtxverbose.
| DecayTreeFitter::Fitter::Fitter | ( | RhoCandidate * | bc, |
| const RhoLorentzVectorErr & | lv, | ||
| RecoTrackStateProvider * | extrapolator, | ||
| int | verbosity = 0 |
||
| ) |
constructor from the particle (decay head) and pbeam
Definition at line 95 of file Fitter.cxx.
References vtxverbose.
| DecayTreeFitter::Fitter::Fitter | ( | RhoCandidate * | bc, |
| const RhoLorentzVectorErr & | lv, | ||
| const RhoVector3Err & | pv, | ||
| RecoTrackStateProvider * | extrapolator = 0, |
||
| int | verbosity = 0 |
||
| ) |
constructor from the particle (decay head), pbeam and primary vertex
Definition at line 124 of file Fitter.cxx.
References vtxverbose.
|
virtual |
destructor
Definition at line 160 of file Fitter.cxx.
|
private |
default constructor is disabled
|
private |
copy constructor is disabled
|
protected |
Definition at line 324 of file Fitter.cxx.
References DecayTreeFitter::ParticleBase::addToConstraintList(), bp, DecayTreeFitter::ParticleBase::initCov(), DecayTreeFitter::ParticleBase::initPar1(), DecayTreeFitter::ParticleBase::initPar2(), offset(), and DecayTreeFitter::ParticleBase::updateIndex().
|
inherited |
access to the fitted candidates
Definition at line 86 of file RhoFitterBase.cxx.
References Double_t, RhoFitterBase::fChi2Map, uid(), and RhoCandidate::Uid().
|
inline |
| ChiSquare DecayTreeFitter::Fitter::chiSquare | ( | RhoCandidate * | p | ) | const |
get the chisquare of everything 'downstream' of a particle
Definition at line 912 of file Fitter.cxx.
|
protectedinherited |
uppermost particle composite in tree
Definition at line 51 of file RhoFitterBase.cxx.
References RhoFactory::Instance(), RhoFactory::NewCandidate(), RhoCandidate::RemoveAssociations(), and RhoCandidate::SetFit().
Referenced by RhoFitterBase::CopyTree().
|
protectedinherited |
Definition at line 61 of file RhoFitterBase.cxx.
References RhoFitterBase::CopyCand(), RhoCandidate::Daughter(), i, RhoCandidate::IsComposite(), RhoCandidate::NDaughters(), and RhoCandidate::SetMotherLink().
Referenced by RhoFitterBase::RhoFitterBase().
|
inlineprotected |
|
inlineprotected |
| RhoDoubleErr DecayTreeFitter::Fitter::decayLengthSum | ( | RhoCandidate * | candA, |
| RhoCandidate * | candB | ||
| ) | const |
Compute the decay length sum of two particles in the decay tree (useful for e.g. B->DD)
Definition at line 514 of file Fitter.cxx.
References DecayTreeFitter::ParticleBase::lenIndex(), DecayTreeFitter::ParticleBase::locate(), and DecayTreeFitter::ParticleBase::mother().
|
protected |
|
inline |
|
inline |
get the extrapolator
Definition at line 172 of file Fitter.h.
References m_extrapolator.
| std::ostream & DecayTreeFitter::Fitter::fillStream | ( | std::ostream & | s | ) | const |
Print the result of the fit.
Definition at line 908 of file Fitter.cxx.
References print().
|
protectedinherited |
Definition at line 149 of file RhoFitterBase.cxx.
References RhoCandidate::Daughter(), RhoFitterBase::fDaughters, RhoCandidate::IsComposite(), RhoCandidate::IsLocked(), and RhoCandidate::NDaughters().
Referenced by Rho4CFitter::Fit(), RhoKinFitter::Fit(), and Rho4CFitter::FitConserveMasses().
|
inherited |
This function has to be overridden by the real algoritms implementations
Definition at line 95 of file RhoFitterBase.cxx.
References RhoFitterBase::fChi2Map, RhoFitterBase::fHeadOfTree, and RhoFitterBase::FitNode().
Referenced by ana_check(), ana_check_psi(), ana_complete(), ana_day1(), ana_invariantmass_2pi_tpc(), ana_multi(), anaDMesonsCharged(), anaideal_complete(), anatut_psi2s(), PndTripleAnaTask::DsDs2317Analysis(), PndPmtTask::Exec(), PndProdAnaTask::Exec(), PndLLbarAnaTask::Exec(), PndMyAnalysisTask::Exec(), PndSimpleCombinerTask::Exec(), FitAll(), PndTripleAnaTask::JpsiAnalysis(), newana_check_eta(), poormantracks(), run_ana_eta_c_stt(), run_ana_eta_c_stt_v2(), run_ana_eta_c_tpc(), run_ana_invariantmass_2pi_stt(), run_ana_invariantmass_2pi_tpc(), run_ana_invariantmass_4pi_stt(), run_ana_invariantmass_4pi_tpc(), run_ana_mertens_evt7(), tut_ana(), tut_ana_fast(), tut_ana_fit(), tut_ana_ntp(), tut_ana_ntp_noqa(), and tut_ana_ntp_qa().
|
inline |
Add or remove a mass constraintfor a certain ParticleID.
Add a constraint to a mass different from the property table mass Fit the decay tree
Definition at line 103 of file Fitter.h.
References fit(), m_particle, m_status, and updateTree().
|
protected |
Fit the decay tree.
Definition at line 171 of file Fitter.cxx.
References fabs(), DecayTreeFitter::ErrCode::fastdivergingfit, max(), print(), DecayTreeFitter::ErrCode::slowdivergingfit, and vtxverbose.
Referenced by Fit().
|
inherited |
Definition at line 101 of file RhoFitterBase.cxx.
References RhoFitterBase::fHeadOfTree, RhoCandidate::IsLocked(), and RhoFitterBase::IterateAndFit().
|
inline |
|
protectedvirtualinherited |
Reimplemented in RhoKinHyperonVtxFitter, RhoKinVtxFitter, and RhoKalmanVtxFitter.
Definition at line 130 of file RhoFitterBase.cxx.
Referenced by RhoFitterBase::Fit(), and RhoFitterBase::IterateAndFit().
|
protected |
Fit just one step.
Definition at line 294 of file Fitter.cxx.
References vtxverbose.
|
inline |
|
inlineprotected |
|
inlineprotected |
|
protected |
|
inlineinherited |
Definition at line 48 of file RhoFitterBase.h.
References RhoFitterBase::fChiSquare.
Referenced by ana_check(), ana_check_psi(), ana_complete(), ana_day1(), ana_multi(), anaideal_complete(), anatut_psi2s(), PndTripleAnaTask::DsDs2317Analysis(), PndPmtTask::Exec(), PndProdAnaTask::Exec(), PndLLbarAnaTask::Exec(), PndAnaWithTrigger::Exec(), PndMyAnalysisTask::Exec(), PndScrutAnaTask::Exec(), PndSimpleCombinerTask::Exec(), PndTripleAnaTask::JpsiAnalysis(), newana_check_eta(), poormantracks(), PndRhoTupleQA::qaFitter(), run_ana_eta_c_stt(), run_ana_eta_c_stt_v2(), run_ana_eta_c_tpc(), PndTripleAnaTask::ThreePiAnalysis(), tut_ana(), tut_ana_fast(), tut_ana_fit(), tut_ana_ntp(), tut_ana_ntp_noqa(), and tut_ana_ntp_qa().
|
inline |
|
inlineinherited |
Definition at line 49 of file RhoFitterBase.h.
References RhoFitterBase::fNDegreesOfFreedom.
Referenced by poormantracks(), and PndRhoTupleQA::qaFitter().
|
inlineinherited |
Definition at line 50 of file RhoFitterBase.h.
References RhoFitterBase::fChiSquare, and RhoFitterBase::fNDegreesOfFreedom.
Referenced by ana_complete(), ana_day1(), ana_multi(), anaideal_complete(), PndPmtTask::Exec(), PndLLbarAnaTask::Exec(), poormantracks(), PndRhoTupleQA::qaFitter(), tut_ana(), tut_ana_fast(), tut_ana_fit(), tut_ana_ntp(), tut_ana_ntp_noqa(), and tut_ana_ntp_qa().
|
protected |
Definition at line 427 of file Fitter.cxx.
|
inlineprotectedinherited |
|
inlineprotectedinherited |
Definition at line 66 of file RhoFitterBase.h.
References RhoFitterBase::fChi2Map, and RhoCandidate::Uid().
Referenced by RhoKalmanVtxFitter::Calculate().
|
protected |
Name of a particle in the decay tree.
Definition at line 539 of file Fitter.cxx.
References DecayTreeFitter::ParticleBase::locate(), and DecayTreeFitter::ParticleBase::name().
| int DecayTreeFitter::Fitter::nDof | ( | ) | const |
|
inline |
assignement operator is disabled
|
inline |
The top level particle that is fitted.
Definition at line 116 of file Fitter.h.
References m_particle.
| std::string DecayTreeFitter::Fitter::print | ( | ) | const |
Print the result of the fit.
Definition at line 307 of file Fitter.cxx.
|
protected |
Definition at line 371 of file Fitter.cxx.
References DecayTreeFitter::ParticleBase::addToConstraintList(), DecayTreeFitter::ParticleBase::mother(), and DecayTreeFitter::ParticleBase::removeDaughter().
|
protectedinherited |
Definition at line 136 of file RhoFitterBase.cxx.
References RhoCandidate::Daughter(), RhoFitterBase::fDaughters, RhoCandidate::IsComposite(), and RhoCandidate::NDaughters().
Referenced by RhoKinHyperonFitter::Fit(), RhoKinVtxFitter::FitNode(), RhoKinHyperonVtxFitter::FitNode(), and RhoKinHyperonFitter::SetMatrices().
|
protectedinherited |
Definition at line 178 of file RhoFitterBase.cxx.
References RhoCandidate::SetDecayVtx().
Referenced by RhoKalmanVtxFitter::Calculate(), RhoKinVtxFitter::SetOutput(), and RhoKinHyperonVtxFitter::SetOutput().
|
protectedinherited |
Definition at line 160 of file RhoFitterBase.cxx.
References RhoCandidate::Cov7(), RhoCandidate::Daughter(), RhoCandidate::IsComposite(), RhoCandidate::IsLocked(), RhoCandidate::NDaughters(), RhoCandidate::P4(), RhoCandidate::SetCov7(), and RhoCandidate::SetP4().
Referenced by RhoKalmanVtxFitter::Calculate(), Rho4CFitter::Fit(), Rho4CFitter::FitConserveMasses(), RhoKinVtxFitter::SetOutput(), and RhoKinFitter::SetOutput().
| void DecayTreeFitter::Fitter::setMassConstraint | ( | RhoCandidate * | cand, |
| bool | add = true |
||
| ) |
Add or remove a mass constraint.
Definition at line 394 of file Fitter.cxx.
| void DecayTreeFitter::Fitter::setMassConstraint | ( | RhoCandidate * | cand, |
| double | mass | ||
| ) |
Add a constraint to a mass different from the property table mass.
Definition at line 400 of file Fitter.cxx.
| void DecayTreeFitter::Fitter::setStateProvider | ( | RecoTrackStateProvider * | extrapolator | ) |
set the track extrapolator
Definition at line 154 of file Fitter.cxx.
|
inline |
Definition at line 161 of file Fitter.h.
References m_extrapolator, and DecayTreeFitter::RecoTrackStateProvider::SetToleranceZ().
|
inlineinherited |
| void DecayTreeFitter::Fitter::setVerbose | ( | int | i | ) |
set the verbosity level (for debugging only)
Definition at line 158 of file Fitter.cxx.
References i, and vtxverbose.
|
inline |
| bool DecayTreeFitter::Fitter::updateCand | ( | RhoCandidate * | cand | ) | const |
update a particlular candidate in the tree
return an updated decay tree. this is not a final solution. will try to move more info to Particle methods to retrieve the result in terms of RhoCandidates (note: mother vertex is not updated, and decay length cannot be stored anywhere. Use fitParams instead methods to retrieve the result in terms of RhoCandidates (note: mother vertex is not updated, and decay length cannot be stored anywhere. Use fitParams instead
Definition at line 875 of file Fitter.cxx.
References DecayTreeFitter::ParticleBase::locate().
|
protected |
Definition at line 736 of file Fitter.cxx.
References col, energy, RhoCandidate::GetFit(), DecayTreeFitter::ParticleBase::hasEnergy(), i, RhoFactory::Instance(), DecayTreeFitter::ParticleBase::lenIndex(), DecayTreeFitter::ParticleBase::momIndex(), DecayTreeFitter::ParticleBase::mother(), RhoFactory::NewCandidate(), DecayTreeFitter::ParticleBase::pdtMass(), pos, DecayTreeFitter::ParticleBase::posIndex(), RhoCandidate::RemoveAssociations(), row, RhoCandidate::SetCov7(), RhoCandidate::SetFit(), RhoCandidate::SetP4(), RhoCandidate::SetPos(), and sqrt().
|
protected |
Definition at line 418 of file Fitter.cxx.
References offset().
| bool DecayTreeFitter::Fitter::updateTree | ( | RhoCandidate * | cand | ) | const |
update a particlular candidate in the tree
Definition at line 894 of file Fitter.cxx.
References RhoCandidate::Daughter(), and RhoCandidate::NDaughters().
Referenced by Fit().
|
protectedinherited |
Definition at line 74 of file RhoFitterBase.h.
Referenced by RhoKalmanVtxFitter::Calculate(), chiSquare(), RhoKinVtxFitter::Compute(), RhoKinHyperonVtxFitter::Compute(), Rho4CFitter::Do4CFit(), Rho4CFitter::Do4CFitWithMassConservation(), RhoKalmanVtxFitter::FitNode(), RhoKalmanVtxFitter::FitVertexFast(), RhoFitterBase::GetChi2(), RhoFitterBase::GetProb(), Rho4CFitter::Rho4CFitter(), RhoKinFitter::Solve(), and RhoKinHyperonFitter::Solve().
|
protectedinherited |
Definition at line 69 of file RhoFitterBase.h.
Referenced by RhoKinVtxFitter::Compute(), RhoKinHyperonVtxFitter::Compute(), Rho4CFitter::Do4CFit(), Rho4CFitter::Do4CFitWithMassConservation(), RhoFitterBase::FindAndAddFinalStateDaughters(), Rho4CFitter::Fit(), RhoKinHyperonFitter::Fit(), RhoKinFitter::Fit(), Rho4CFitter::FitConserveMasses(), RhoKinVtxFitter::GetCovariance(), RhoKinHyperonVtxFitter::GetCovariance(), RhoKinFitter::Read4MomKinMatrix(), RhoKinHyperonFitter::Read4MomKinMatrix(), RhoKinVtxFitter::ReadKinMatrix(), RhoKinHyperonVtxFitter::ReadKinMatrix(), RhoKinVtxFitter::ReadMassKinMatrix(), RhoKinFitter::ReadMassKinMatrix(), RhoKinHyperonVtxFitter::ReadMassKinMatrix(), RhoKinVtxFitter::ReadMatrix(), RhoKinFitter::ReadMatrix(), RhoKinHyperonVtxFitter::ReadMatrix(), RhoKinFitter::ReadMomKinMatrix(), RhoKinHyperonFitter::ReadMomKinMatrix(), RhoKinFitter::ReadTotEKinMatrix(), RhoKinHyperonFitter::ReadTotEKinMatrix(), RhoKinFitter::ReadTotMomKinMatrix(), RhoKinHyperonFitter::ReadTotMomKinMatrix(), RhoFitterBase::SetDaugthersFromComposite(), RhoKinVtxFitter::SetMatrices(), RhoKinFitter::SetMatrices(), RhoKinHyperonFitter::SetMatrices(), RhoKinHyperonVtxFitter::SetMatrices(), RhoKinVtxFitter::SetOutput(), RhoKinFitter::SetOutput(), RhoKinHyperonFitter::SetOutput(), RhoKinHyperonVtxFitter::SetOutput(), RhoKinHyperonVtxFitter::TransportToPoca(), RhoKinVtxFitter::TransportToVertex(), and RhoKinHyperonVtxFitter::TransportToVertex().
|
protectedinherited |
Definition at line 62 of file RhoFitterBase.h.
Referenced by Rho4CFitter::Fit(), RhoKinFitter::Fit(), RhoKinHyperonFitter::Fit(), RhoFitterBase::Fit(), RhoFitterBase::FitAll(), Rho4CFitter::FitConserveMasses(), RhoFitterBase::HeadOfTree(), RhoKinHyperonFitter::ReadMatrix(), RhoFitterBase::RhoFitterBase(), RhoKalmanVtxFitter::RhoKalmanVtxFitter(), RhoKinHyperonFitter::SetMatrices(), RhoKinFitter::SetOutput(), and RhoKinHyperonFitter::SetOutput().
|
protectedinherited |
Definition at line 75 of file RhoFitterBase.h.
Referenced by RhoKalmanVtxFitter::Calculate(), RhoKinVtxFitter::Compute(), RhoKinHyperonVtxFitter::Compute(), Rho4CFitter::Do4CFit(), Rho4CFitter::Do4CFitWithMassConservation(), RhoKalmanVtxFitter::FitVertexFast(), RhoFitterBase::GetNdf(), RhoFitterBase::GetProb(), RhoKinFitter::SetOutput(), and RhoKinHyperonFitter::SetOutput().
|
protectedinherited |
Definition at line 58 of file RhoFitterBase.h.
Referenced by RhoKalmanVtxFitter::Calculate(), RhoKinVtxFitter::Compute(), RhoKinHyperonVtxFitter::Compute(), RhoKalmanVtxFitter::FitVertexFast(), RhoKalmanVtxFitter::RhoKalmanVtxFitter(), RhoKalmanVtxFitter::SetDebug(), RhoKinVtxFitter::SetOutput(), RhoKinHyperonVtxFitter::SetOutput(), RhoKalmanVtxFitter::SetSilent(), and RhoFitterBase::SetVerbose().
|
private |
Definition at line 222 of file Fitter.h.
Referenced by decaychain(), and GetDecayChainDirty().
|
private |
|
protected |
track extrapolator (if needed)
Definition at line 235 of file Fitter.h.
Referenced by extrapolator(), and SetToleranceZ().
|
private |
Definition at line 223 of file Fitter.h.
Referenced by fitparams().
|
private |
|
private |
Definition at line 221 of file Fitter.h.
Referenced by Fit(), and particle().
|
private |
1.8.8