11 #include "Math/ParamFunctor.h" 
   12 #include <Minuit2/FCNBase.h> 
   17 #include "EVENT/TrackerPulse.h" 
   18 #include <EVENT/LCFloatVec.h> 
   19 #include <IMPL/TrackerPulseImpl.h> 
   20 #include <IMPL/TrackerHitImpl.h> 
   21 #include <IMPL/TrackImpl.h> 
   24 #include <gear/TPCParameters.h> 
   25 #include <gear/TPCModule.h> 
   26 #include <gearimpl/GlobalPadIndex.h> 
   29 #include <marlin/Global.h> 
   32 #include "MMPadResponseFunction.h" 
   33 #include "TrackFitterFactory.h" 
   34 #include "TrackFitterBase.h" 
   35 #include "LCObjectCopier.h" 
   54                         MMRefitTool(
int fitType, 
int nPar, std::string prfType, 
bool rowDep, 
const IMPL::TrackImpl* seed, 
bool fitTrack, 
int normType, 
bool padHits);
 
   59         std::vector<MMPadResponseFunction>().swap(_prfs);
 
   60         std::map<int, int>().swap(_moduleList);
 
   64         _fit_type = other._fit_type;
 
   66         _prfType = other._prfType;
 
   67         _rowDep = other._rowDep;
 
   68         _moduleDep = other._moduleDep;
 
   69         _seedTrack = other._seedTrack;
 
   70         _fitTrack = other._fitTrack;
 
   71         _normType = other._normType;
 
   72         _padHits = other._padHits;
 
   73         _moduleList = other._moduleList;
 
   74         _theErrorDef = other._theErrorDef;
 
   80         else if(_fit_type == 1)
 
   87         _fit_type = other._fit_type;
 
   89         _prfType = other._prfType;
 
   90         _rowDep = other._rowDep;
 
   91         _moduleDep = other._moduleDep;
 
   92         _seedTrack = other._seedTrack;
 
   93         _fitTrack = other._fitTrack;
 
   94         _normType = other._normType;
 
   95         _padHits = other._padHits;
 
   96         _moduleList = other._moduleList;
 
   97         _theErrorDef = other._theErrorDef;
 
  102         else if(_fit_type == 1)
 
  108                         void setModules(
const std::vector<int>& modules)
 
  112                                 for(
unsigned int i = 0; i < modules.size(); i++)
 
  113                                         _moduleList[modules[i]] = i;
 
  117                         virtual double Up()
 const{
 
  121                         double operator()(
const std::vector<double>& x)
 const {
 
  122                                 double * xx = 
new double[x.size()];
 
  123                                 for(
unsigned int i = 0; i < x.size(); i++)  xx[i] = x[i];
 
  128                         double operator()(
const double* x) 
const ;   
 
  130                         void SetErrorDef(
double def){
 
  134                         std::vector<double> retrievePar(
const double* x);
 
  135                         std::vector<double> retrieveChi2(
const double* x);
 
  141                         std::string _prfType;
 
  144                         const IMPL::TrackImpl * _seedTrack;
 
  149                         std::map<int, int>  _moduleList;
 
  155                         std::vector<MMPadResponseFunction> _prfs;
 
  157                         void padData(
const EVENT::TrackerPulse * , 
const EVENT::LCObjectVec& , std::vector< std::pair <double, float> >& ) 
const;
 
  158                         double calcRowDep(
const double * x, 
int index, 
int row) 
const;
 
static const unsigned char LINEARREGRESSION
Linear regression for a straight line. 
Definition: TrackFitterBase.h:61
 
static const unsigned char SIMPLEHELIXFIT
Simple Helix Fit from V.Karimaeki: "Effective circle fitting for particle trajectories". 
Definition: TrackFitterBase.h:65
 
static TrackFitterBase * getTrackFitter(unsigned char fitterType, EVENT::LCParameters const *collectionParameters, EVENT::LCEvent const *event=0)
Get a track fitter and reinitialise its parameters. 
Definition: TrackFitterFactory.cc:23
 
The TrackFitterBase is a virtual class from which the actual track fitters are derived. 
Definition: TrackFitterBase.h:44