void DBtxt_AlgFitTrackSR_default(void)
{
  AlgFactory &af = AlgFactory::GetInstance();
  AlgHandle alh = af.GetAlgHandle("AlgFitTrackSR","default");
  AlgConfig &alg = alh.GetAlgConfig(); 

  alg.UnLockValues();
  alg.UnLockKeys();

  alg.Set("MaxIterate",10);
// when fit momentum stops changing by more than this amount stop iterations
  alg.Set("MaxIterate2",5);
// number of total loops including removal and addition of hits
  alg.Set("QPDiff",0.02);
  alg.Set("MaxQP",4.);
  alg.Set("MaxAngle",25.);
  alg.Set("MaxImpactParameter", 4.25); //maximum impact parameter for a track clustser to be used on track

// need 2 consecutive planes with this many PE's to define begin and end
// of event (for vertex and end extrapolation)
  alg.Set("MinPlanePE",3.);
// last active plane in detector
// want to get this value from geometry when available
  alg.Set("LastPlane",485);
  
  alg.Set("IsCosmic",1);

  alg.Set("MaxLocalChi2",30.);    // maximum filtered chi2 each hit
  alg.Set("MaxLocalPreChi2",30.); // maximum predicted chi2 each hit
  alg.Set("MaxAngleCovariance",200.); // maximum allowed square of du/dz and dv/dz uncertainty

  alg.Set("NSkipView",3); // up to 3 missing planes allowed each view
  alg.Set("NSkipActive",3); // up to 3 missing active planes allowed

// The Pass parameters below defines whether a track fit was successful
  alg.Set("PassReducedChi2",4.); // maximum reduced chi2
  alg.Set("PassPlaneAsymmetry",0.2); // maximum (nplaneu-nplanev)/nplane
  alg.Set("PassMinPlaneAsymmetry",20); // minimum nplane for asymmetry test, also use for chi2 test
  
  if (alg.GetInt("IsCosmic")==1) {
    alg.Set("FitInputHits",1);
  }
  else {
    alg.Set("FitInputHits",0);
  }

  alg.Set("Swimmer",2);
 
  alg.Set("SeedTrkNStrip",8);
  alg.Set("SeedTrkNStripView",2); // min # of hits in each view for seed track

  alg.Set("TPosError2",1.4*Munits::cm2); // in cm**2

  alg.Set("InitialPositionError2",2500.*Munits::cm2); // in cm**2
  alg.Set("InitialSlopeError2",100.0);
// in (GeV/c)**-2 ; charge is in units of positron charge, c is set to 1
  alg.Set("InitialQPError2",1./Munits::GeV/Munits::GeV);

  alg.Set("CovarianceScale",100.); // at start of each fit, multiply previous filtered covariance matrix by this scale to use as initial covariance

 //parameters added in code revision
  alg.Set("MinClusterCharge",2.);
  alg.Set("MaxClusterNStrip",10);
  alg.Set("DeltaChi2",-1.);
  alg.Set("DeltaCovariance",-1.);
  alg.Set("MisalignmentError",2.);

  //_______________________________________________

  alg.Set("KalmanDState1",.01);
  alg.Set("KalmanDState2",.01);
  alg.Set("KalmanDState3",0.0025);
  alg.Set("KalmanDState4",0.0025);
  alg.Set("KalmanDState5",0.05); // fraction of q/p, not to drop below 0.01

  alg.Set("KalmanPlnRadLen",1.47); // of radiation lengths per iron plane
  alg.Set("Kalmandedx",0.038); // energy loss (in GeV) per iron plane

  alg.Set("KalmanQPRangeCheck",0); // perform check if Pfit>Prange 
  alg.Set("KalmanMaxQP",4.); // maximum abs(q/p)
  alg.Set("KalmanMaxQPFrac",1.2); // maximum abs(q/p), based on range measurement*KalmanMaxQPFrac
  alg.Set("KalmanMaxAngle",25.); // maximum du/dz, dv/dz


  alg.Set("HitDTime0",-20*Munits::ns); // hit - track time > DTime0
  alg.Set("HitDTime1", 50*Munits::ns); // hit - track time < DTime0


  alg.LockValues();
  alg.LockKeys();
}


