Upldate to latest analzer 1.5 with Hall C specific THaTrack members
Modify cuts definition for the HMS calrimeter calibration.

In hcal_calib/hcal_replay_cuts.def:
   add one_clust condition;
   activate good_beta condition (defined for run 52949);
   define 2 versions of the Reconstruct_master cut, one for initial
   calibration and another for iterative calibration.
Make counting of calorimeter tracks consistent with Engine.

Increment fNtracks++ each time a cluster matches a spectrometer
track. Only best matches were counted before. Move fNtracks++ from
THcShower::CoarceProcess to THcShower:MatchCluster.
Add method for getting coordinate corrected track total energy in the
calorimeter.

Add list of clusters fClusterList in THcShower class.
Add method THcShower::GetShEnergy(THaTrack*).
Add method THcShowerClusterList::clear() in THcShowerCluster.h.
Add example code to assign energies to tracks.

    Add TrackEnergies method in THcHallCSpectrometer class. It is
    called from TrackCalc metod.
Revise misplaced lines in THcShower:GetShEnergy method which caused
crashes.
Add per event purge of ShowerClusterList in order to reduce grow of
memory consumption with event number.

       Add THcShowerClusterList::purge() method to purge and clean
       THcShower::fClusterList by the end of each event, in
       THcShower::Clear().
Move energy to track assignment from THcHallCSpectrometer to the
shower counter's FineProcess.

       Remove THcHallCSpectrometer::TrackEnergies method.
       Add GetShEnergy call for each tack in THcShower::fineProcess.
Beta:
This commmit is only for Beta. THcHodoscope is modified and few
bugs are fixed. I will not make pull request for this commit.
Pull request will be made after the completion of Golden track
in THcHallCSpectrometer.
Golden track.
  Goldent track is moved to THcHallCSpectrometer::TrackCalc()
  if  fSelUsingScin == 0 then golden track is calculated just
  like podd. i.e. it is the first track with minimum chi2/ndf
  with sorting ON

  if fSelUsingScin == 1 then golden track is calculetd just like
  engine/HTRACKING/h_select_best_track_using_scin.h. This method
  gives the best track with minimum value of chi2/ndf but with
  additional cuts on the tracks. These cuts are on dedx, beta
  and on energy.

  This commit also corrects and modifies the beta code written
  in the THcHodoscope::FineProcess

  At this point we have godlend track and in additoion to
  previous vlues the following values are set to a track:
  Energy, beta, chi2 of beta and dedx[track][first hit].

NOTE: For some tracks we have large differences in value of chi
      square between ENGINE and hcana and this is already
      discussed in the last group meeting. Following emails are
      exchanged regarding this difference of chisquare.

email to Mark:

Hi Mark,
I tried to trace the origin of difference of the chi square value between
ENGINE and hcana. Please see the attached file, it has long table which I
cannot present in this email. Or you can see the file at the following
link, thanks.

https://userweb.jlab.org/~zahmed/chi2diff.txt

Ahmed

Mark's reply:
Ahmed,
        Thanks. I agree with what you see, but there is also another reason
for the difference. For the space point in ch2 the engine and hcana
choose different left/right combinations. That is why you see the large
jump in the summed chi2 from planes 9 and 10. The two codes pick
different left/right because there is a cut on the difference between the
measured stub xp and an expected xp = sp->GetX()/875  and one code has a combination
slightly below the cut value and the other slightly above. I do not see a way
to make the codes agree more exactly since the stub fitting involves a matrix
inversion.

                Cheers,
                       Mark

---------------------------------------------------------------------------------------
Golden track.
Bugs fixed.
Golden track:

Goldent track is moved to THcHallCSpectrometer::TrackCalc()
  if  fSelUsingScin == 0 then golden track is calculated just
  like podd. i.e. it is the first track with minimum chi2/ndf
  with sorting ON

  if fSelUsingScin == 1 then golden track is calculetd just like
  engine/HTRACKING/h_select_best_track_using_scin.h. This method
  gives the best track with minimum value of chi2/ndf but with
  additional cuts on the tracks. These cuts are on dedx, beta
  and on energy.

  This commit also corrects and modifies the beta code written
  in the THcHodoscope::FineProcess

  At this point we have godlend track and in additoion to
  previous vlues the following values are set to a track:
  Energy, beta, chi2 of beta and dedx[track][first hit].

NOTE: For some tracks we have large differences in value of chi
      square between ENGINE and hcana and this is already
      discussed in the last group meeting. Following emails are
      exchanged regarding this difference of chisquare.

email to Mark:

Hi Mark,
I tried to trace the origin of difference of the chi square value between
ENGINE and hcana. Please see the attached file, it has long table which I
cannot present in this email. Or you can see the file at the following
link, thanks.

https://userweb.jlab.org/~zahmed/chi2diff.txt

Ahmed

Mark's reply:
Ahmed,
        Thanks. I agree with what you see, but there is also another reason
for the difference. For the space point in ch2 the engine and hcana
choose different left/right combinations. That is why you see the large
jump in the summed chi2 from planes 9 and 10. The two codes pick
different left/right because there is a cut on the difference between the
measured stub xp and an expected xp = sp->GetX()/875  and one code has a combination
slightly below the cut value and the other slightly above. I do not see a way
to make the codes agree more exactly since the stub fitting involves a matrix
inversion.

                Cheers,
                       Mark
 Golden track:

Goldent track is moved to THcHallCSpectrometer::TrackCalc()
  if  fSelUsingScin == 0 then golden track is calculated just
  like podd. i.e. it is the first track with minimum chi2/ndf
  with sorting ON

  if fSelUsingScin == 1 then golden track is calculetd just like
  engine/HTRACKING/h_select_best_track_using_scin.h. This method
  gives the best track with minimum value of chi2/ndf but with
  additional cuts on the tracks. These cuts are on dedx, beta
  and on energy.

  This commit also corrects and modifies the beta code written
  in the THcHodoscope::FineProcess

  At this point we have godlend track and in additoion to
  previous vlues the following values are set to a track:
  Energy, beta, chi2 of beta and dedx[track][first hit].

NOTE: For some tracks we have large differences in value of chi
      square between ENGINE and hcana and this is already
      discussed in the last group meeting. Following emails are
      exchanged regarding this difference of chisquare.

email to Mark:

Hi Mark,
I tried to trace the origin of difference of the chi square value between
ENGINE and hcana. Please see the attached file, it has long table which I
cannot present in this email. Or you can see the file at the following
link, thanks.

https://userweb.jlab.org/~zahmed/chi2diff.txt

Ahmed

Mark's reply:
Ahmed,
        Thanks. I agree with what you see, but there is also another reason
for the difference. For the space point in ch2 the engine and hcana
choose different left/right combinations. That is why you see the large
jump in the summed chi2 from planes 9 and 10. The two codes pick
different left/right because there is a cut on the difference between the
measured stub xp and an expected xp = sp->GetX()/875  and one code has a combination
slightly below the cut value and the other slightly above. I do not see a way
to make the codes agree more exactly since the stub fitting involves a matrix
inversion.

                Cheers,
                       Mark
Merge pull request #66 from zahmed9/zafarA2

Zafar a2 Golden Track