FitStateDiverged Class Reference

#include <FitStateDiverged.h>

Inheritance diagram for FitStateDiverged:
FitState

List of all members.

Public Member Functions

void Iterate (FitContext &context) const
const std::string & Name () const

Detailed Description

FitStateDiverged is the diverged state - Iterate calculates number of planes to fit during next iteration.

Author:
Sergei avva@fnal.gov

Definition at line 17 of file FitStateDiverged.h.


Member Function Documentation

void FitStateDiverged::Iterate ( FitContext context  )  const [virtual]

Iterate

Iterate method

Implements FitState.

Definition at line 54 of file FitStateDiverged.cxx.

References FitContext::fConvergenceMaster, FitContext::fData, FitContext::fDChi2, FitContext::fNIterationsStep, FitContext::fNTriesDiverges, ConvergenceMaster::GetMaskUCur(), ConvergenceMaster::GetMaskVCur(), ConstFT::InitialDChi2, FitStateFactory::Instance(), Msg::kInfo, ConvergenceMaster::MaskIsValid(), MSG, ConvergenceMaster::NextStep(), FitContext::SetFromLastGoodFit(), ConvergenceMaster::SetMaskIsValid(), FitContext::SetState(), DataFT::SetUHitUse(), and DataFT::SetVHitUse().

00055 {
00056     // reset number of iterations
00057     context.fNIterationsStep = 0;
00058        
00059     // reset number of diverging iterations
00060     context.fNTriesDiverges = 0;   
00061     
00062     // next step in dearch of convergence
00063     if ( context.fConvergenceMaster.NextStep() ) {    
00064         if ( ! context.fConvergenceMaster.MaskIsValid() ) { 
00065             // apply the next mask
00066             context.fData.SetUHitUse( context.fConvergenceMaster.GetMaskUCur() );
00067             context.fData.SetVHitUse( context.fConvergenceMaster.GetMaskVCur() );
00068             context.fConvergenceMaster.SetMaskIsValid(kTRUE);
00069             MSG("FitTrackSA",Msg::kInfo) << "Updated U, V Masks.\n";
00070         }    
00071         context.fDChi2 = ConstFT::InitialDChi2;
00072         context.SetFromLastGoodFit();
00073         context.SetState(FitStateFactory::Instance().GetFitState("Iterating"));
00074         //context.Print();
00075         MSG("FitTrackSA",Msg::kInfo) << "Switched from Diverged to Iterating\n";
00076     } else {
00077         context.SetState(FitStateFactory::Instance().GetFitState("Final"));
00078         //context.Print();
00079         MSG("FitTrackSA",Msg::kInfo) << "Switched from Diverged to Final\n";
00080         return;
00081     }
00082     
00083 }

const std::string & FitStateDiverged::Name (  )  const [virtual]

Name() - return name of the state

Implements FitState.

Definition at line 45 of file FitStateDiverged.cxx.

References DIVERGED_FIT_STATE.

00046 {
00047     return DIVERGED_FIT_STATE;
00048 }    


The documentation for this class was generated from the following files:

Generated on 2 Nov 2017 for loon by  doxygen 1.6.1