Index: /trunk/MagicSoft/Mars/Changelog
===================================================================
--- /trunk/MagicSoft/Mars/Changelog	(revision 7224)
+++ /trunk/MagicSoft/Mars/Changelog	(revision 7225)
@@ -20,4 +20,20 @@
 
                                                  -*-*- END OF LINE -*-*-
+
+ 2005/07/27 Markus Meyer, Thomas Bretz
+
+   * mmuon/MHSingleMuon.[h,cc]:
+     - added third (constant) parameter to arc width gaus fit
+     - replaced nonsense GetMaximumBin as start value for fit
+       by GetMaximum
+     - replaced TH1F for fHistWidth by TProfile
+
+   * mmuon/MMuonSetup.cc:
+     - set new threshold for arc width plot to 2
+
+   * star.rc:
+     - replaced default for arc width threshold
+
+
 
  2005/07/27 Thomas Bretz
Index: /trunk/MagicSoft/Mars/NEWS
===================================================================
--- /trunk/MagicSoft/Mars/NEWS	(revision 7224)
+++ /trunk/MagicSoft/Mars/NEWS	(revision 7225)
@@ -124,5 +124,11 @@
    - star: Output now contains MReportStarguider
 
-   - ganymed: corrects now (correctly?) for the misspointing in May/April 05
+   - star: Improved muon analysis. Due to the absense of a constant
+           for the gaus fit for arc width and the fact that the arcwidth
+           plot was a histogram instead of a profile the resulting psf
+           became pedestal rms dependant
+
+   - ganymed: corrects now (correctly?) for the misspointing in 
+              May/April 05
 
    - ganymed: Two new default templates for ganymed.rc are avilable:
Index: /trunk/MagicSoft/Mars/mmuon/MHSingleMuon.cc
===================================================================
--- /trunk/MagicSoft/Mars/mmuon/MHSingleMuon.cc	(revision 7224)
+++ /trunk/MagicSoft/Mars/mmuon/MHSingleMuon.cc	(revision 7225)
@@ -244,5 +244,5 @@
 // below the threshold is found, kFALSE is returned.
 //
-Bool_t MHSingleMuon::FindRangeAboveThreshold(const TH1F &h, Float_t thres, Int_t &first, Int_t &last) const
+Bool_t MHSingleMuon::FindRangeAboveThreshold(const TH1 &h, Float_t thres, Int_t &first, Int_t &last) const
 {
     const Int_t n      = h.GetNbinsX();
@@ -348,12 +348,13 @@
 
     // Setup the function and perform the fit
-    TF1 f1("f1", "gaus", startfitval, endfitval);
+    TF1 f1("f1", "gaus + [3]", startfitval, endfitval);
     f1.SetLineColor(kBlue);
 
     // Choose starting values as accurate as possible
-    f1.SetParameter(0, fHistWidth.GetMaximumBin());
+    f1.SetParameter(0, fHistWidth.GetMaximum());
     f1.SetParameter(1, fHistWidth.GetBinCenter(m));
 //    f1.SetParameter(2, (endfitval-startfitval)/2);
     f1.SetParameter(2, 0.1);
+    f1.SetParameter(3, 1.8);
 
     // options : N  do not store the function, do not draw
Index: /trunk/MagicSoft/Mars/mmuon/MHSingleMuon.h
===================================================================
--- /trunk/MagicSoft/Mars/mmuon/MHSingleMuon.h	(revision 7224)
+++ /trunk/MagicSoft/Mars/mmuon/MHSingleMuon.h	(revision 7225)
@@ -5,6 +5,6 @@
 #include "MH.h"
 #endif
-#ifndef ROOT_TH1
-#include <TH1.h>
+#ifndef ROOT_TProfile
+#include <TProfile.h>
 #endif
 
@@ -24,8 +24,8 @@
     Double_t fMargin;               //!
 
-    TH1F fHistPhi;   // Histogram of photon distribution along the arc.
-    TH1F fHistWidth; // Histogram of radial photon distribution of the arc.
+    TH1F     fHistPhi;   // Histogram of photon distribution along the arc.
+    TProfile fHistWidth; // Histogram of radial photon distribution of the arc.
 
-    Bool_t FindRangeAboveThreshold(const TH1F &h, Float_t thres, Int_t &first, Int_t &last) const;
+    Bool_t FindRangeAboveThreshold(const TH1 &h, Float_t thres, Int_t &first, Int_t &last) const;
 
 public:
@@ -39,5 +39,5 @@
 
     const TH1F &GetHistPhi() const { return fHistPhi; }
-    const TH1F &GetHistWidth() const { return fHistWidth; }
+    const TProfile &GetHistWidth() const { return fHistWidth; }
 
     void Draw(Option_t *o="");
Index: /trunk/MagicSoft/Mars/mmuon/MMuonSetup.cc
===================================================================
--- /trunk/MagicSoft/Mars/mmuon/MMuonSetup.cc	(revision 7224)
+++ /trunk/MagicSoft/Mars/mmuon/MMuonSetup.cc	(revision 7225)
@@ -49,5 +49,5 @@
 //
 MMuonSetup::MMuonSetup(const char *name, const char *title)
-    : fMargin(0.2), fThresholdArcPhi(30), fThresholdArcWidth(30)
+    : fMargin(0.2), fThresholdArcPhi(30), fThresholdArcWidth(2)
 {
     fName  = name  ? name  : "MMuonSetup";
@@ -60,5 +60,5 @@
 //   MMuonSetup.Margin:            0.2
 //   MMuonSetup.ThresholdArcPhi:   30
-//   MMuonSetup.ThresholdArcWidth: 30
+//   MMuonSetup.ThresholdArcWidth: 2
 //
 Int_t MMuonSetup::ReadEnv(const TEnv &env, TString prefix, Bool_t print)
Index: /trunk/MagicSoft/Mars/star.rc
===================================================================
--- /trunk/MagicSoft/Mars/star.rc	(revision 7224)
+++ /trunk/MagicSoft/Mars/star.rc	(revision 7225)
@@ -58,5 +58,5 @@
 #MMuonSetup.Margin:            0.2
 #MMuonSetup.ThresholdArcPhi:   30
-#MMuonSetup.ThresholdArcWidth: 30
+#MMuonSetup.ThresholdArcWidth: 2
 
 #BinningRadius.Raw:            20  0.5  1.5
