Index: trunk/MagicSoft/Mars/BUGS
===================================================================
--- trunk/MagicSoft/Mars/BUGS	(revision 966)
+++ trunk/MagicSoft/Mars/BUGS	(revision 967)
@@ -4,5 +4,2 @@
 -------------------
 
- - if you try to use the constructor MFillH(const char *, ...)
-   in a precompiled program, the program will fail.
-   MFillH(MParContainer *, ...) works
Index: trunk/MagicSoft/Mars/Changelog
===================================================================
--- trunk/MagicSoft/Mars/Changelog	(revision 966)
+++ trunk/MagicSoft/Mars/Changelog	(revision 967)
@@ -1,3 +1,49 @@
                                                                   -*-*- END -*-*-
+
+ 2001/10/05: Thomas Bretz
+
+   * mbase/MReadTree.[h,cc]:
+     - added some output statements
+     - added comments
+     - added UseLeaf
+     - changed AddFile to Int_t
+     - simplified GetEntry call
+
+   * mgui/MGeomCam.[h,cc], MGeomCamCT1.[h,cc], MGeomCamMagic.[h,cc]:
+     - added come comments
+     - removed Draw-function
+   
+   * mars.cc:
+     - Changed name of TROOT object to 'mars'
+
+   * merpp.cc:
+     - changed name of TROOT object to 'merpp'
+     - added some more ouput
+
+   * mbase/MBaseLinkDef.h:
+     - added MRootFileBranch
+     - added MRootFileTree
+
+   * mgui/MGeomPix.cc, mbase/MClone.cc, mraw/MRawRunHeader.cc:
+     - added comments
+
+   * mbase/MEvtLoop.cc:
+     - added missing include
+     - added another time output
+
+   * mbase/MWriteRootFile.cc:
+     - added ClassImp
+   
+   * mhist/MFillH.cc, mmontecarlo/MMcCollectionAreaCalc.cc:
+     - changed output
+   
+   * mhist/MHMcCollectionArea.cc:
+     - small fixes
+     - changed error calculation according to Ciro
+
+   * macros/CT1Hillas.C:
+     - fixes some bugs (typos)
+
+
 
  2001/10/05: Thomas Bretz
Index: trunk/MagicSoft/Mars/macros/CT1Hillas.C
===================================================================
--- trunk/MagicSoft/Mars/macros/CT1Hillas.C	(revision 966)
+++ trunk/MagicSoft/Mars/macros/CT1Hillas.C	(revision 967)
@@ -83,11 +83,11 @@
     //
     MEvtLoop evtloop;
-    if (!evtloop.SetParList(&plist))
-        return;
+    evtloop.SetParList(&plist)
 
     //
     // Execute your analysis
     //
-    evtloop.Eventloop();
+    if (!evtloop.Eventloop())
+        return;
 
     //
Index: trunk/MagicSoft/Mars/manalysis/MCerPhotPix.h
===================================================================
--- trunk/MagicSoft/Mars/manalysis/MCerPhotPix.h	(revision 966)
+++ trunk/MagicSoft/Mars/manalysis/MCerPhotPix.h	(revision 967)
@@ -11,8 +11,12 @@
 
     Int_t   fPixId;       // the pixel Id
+
     Bool_t  fIsUsed;      // the pixel is used for calculations --> kTRUE
     Bool_t  fIsCore;      // the pixel is a Core pixel          --> kTRUE
+
     Float_t fPhot;        // The number of Cerenkov photons
     Float_t fErrPhot;     // the error of fPhot
+
+    // FIXME: arrival time t, and it's error sigma t
 
 public:
Index: trunk/MagicSoft/Mars/mbase/BaseLinkDef.h
===================================================================
--- trunk/MagicSoft/Mars/mbase/BaseLinkDef.h	(revision 966)
+++ trunk/MagicSoft/Mars/mbase/BaseLinkDef.h	(revision 967)
@@ -34,4 +34,8 @@
 
 #pragma link C++ class MReadTree;
+
+#pragma link C++ class MRootFileBranch;
+#pragma link C++ class MRootFileTree;
+
 #pragma link C++ class MWriteFile;
 #pragma link C++ class MWriteAsciiFile;
Index: trunk/MagicSoft/Mars/mbase/MClone.cc
===================================================================
--- trunk/MagicSoft/Mars/mbase/MClone.cc	(revision 966)
+++ trunk/MagicSoft/Mars/mbase/MClone.cc	(revision 967)
@@ -39,4 +39,7 @@
 //  The object does only exist until a new object is cloned. It is deleted  //
 //  in the destructor.                                                      //
+//                                                                          //
+//  To use MClone you must make sure, that TObject::Clone is correctly      //
+//  working for this class (maybe you have to overload it)                  //
 //                                                                          //
 //  Input Containers:                                                       //
Index: trunk/MagicSoft/Mars/mbase/MEvtLoop.cc
===================================================================
--- trunk/MagicSoft/Mars/mbase/MEvtLoop.cc	(revision 966)
+++ trunk/MagicSoft/Mars/mbase/MEvtLoop.cc	(revision 967)
@@ -195,8 +195,13 @@
     clock.Print();
 
-    *fLog << dec << endl
+    *fLog << dec << endl << "CPU   - "
         << "Time: " << clock.CpuTime() << "s"
         << " for " << (maxcnt<0?dummy:maxcnt) << " Events"
         << " --> " << (maxcnt<0?dummy:maxcnt)/clock.CpuTime() << " Events/s"
+        << endl;
+    *fLog << "Total - "
+        << "Time: " << clock.RealTime() << "s"
+        << " for " << (maxcnt<0?dummy:maxcnt) << " Events"
+        << " --> " << (maxcnt<0?dummy:maxcnt)/clock.RealTime() << " Events/s"
         << endl << endl;
 }
Index: trunk/MagicSoft/Mars/mbase/MWriteRootFile.cc
===================================================================
--- trunk/MagicSoft/Mars/mbase/MWriteRootFile.cc	(revision 966)
+++ trunk/MagicSoft/Mars/mbase/MWriteRootFile.cc	(revision 967)
@@ -43,4 +43,7 @@
 #include "MParList.h"
 
+ClassImp(MRootFileBranch);
+ClassImp(MRootFileTree);
+
 ClassImp(MWriteRootFile);
 
Index: trunk/MagicSoft/Mars/mhist/MFillH.cc
===================================================================
--- trunk/MagicSoft/Mars/mhist/MFillH.cc	(revision 966)
+++ trunk/MagicSoft/Mars/mhist/MFillH.cc	(revision 967)
@@ -150,5 +150,5 @@
         if (!fParContainer)
         {
-            *fLog << dbginf << fParContainerName << " not found... aborting." << endl;
+            *fLog << dbginf << fParContainerName << " [MParContainer] not found... aborting." << endl;
             return kFALSE;
         }
Index: trunk/MagicSoft/Mars/mhist/MHMcCollectionArea.cc
===================================================================
--- trunk/MagicSoft/Mars/mhist/MHMcCollectionArea.cc	(revision 966)
+++ trunk/MagicSoft/Mars/mhist/MHMcCollectionArea.cc	(revision 967)
@@ -52,5 +52,5 @@
 
 
-    fHistAll = new TH2D("All Events", "All showers - Radius vs log(E) distribution",
+    fHistAll = new TH2D("AllEvents", "All showers - Radius vs log(E) distribution",
                         50, 0., 5.,
                         50, 0., 500.);
@@ -60,5 +60,5 @@
     fHistAll->SetZTitle("N");
 
-    fHistSel = new TH2D("Selected Events", "Selected showers - Radius vs log(E) distribution",
+    fHistSel = new TH2D("SelectedEvents", "Selected showers - Radius vs log(E) distribution",
                         50, 0., 5.,
                         50, 0., 500.);
@@ -68,9 +68,9 @@
     fHistSel->SetYTitle("N");
 
-    fHistCol = new TH1D("Area", "Collection Area vs. log(E)",
+    fHistCol = new TH1D("CollectionArea", "Collection Area vs. log(E)",
                         50, 0., 5.);
 
     fHistCol->SetXTitle("log(E/GeV)");
-    fHistCol->SetYTitle("A/m^2");
+    fHistCol->SetYTitle("A/m^{2}");
 }
 
@@ -204,5 +204,4 @@
         for (Int_t iy=1; iy<=nbiny; iy++)
         {
-            const Float_t Ns = fHistSel->GetCellContent(ix, iy);
             const Float_t Na = fHistAll->GetCellContent(ix, iy);
 
@@ -210,6 +209,12 @@
                 continue;
 
+            const Float_t Ns = fHistSel->GetCellContent(ix, iy);
+
             const Double_t eff = Ns/Na;
-            const Double_t err = sqrt(Na + Na*Ns - Ns*Ns - Ns) / (Na*Na);
+            const Double_t err = sqrt((1.-eff)*Ns)/Na;
+
+            // old calculation from Harald:
+            //  const Double_t eff = Ns/Na;
+            //  const Double_t err = sqrt(Na + Na*Ns - Ns*Ns - Ns) / (Na*Na);
 
             fHistSel->SetCellContent(ix, iy, eff);
@@ -229,6 +234,8 @@
         for (Int_t iy=1; iy<=nbiny; iy++)
         {
-            const Double_t r1  = fHistSel->GetYaxis()->GetBinLowEdge(iy);
-            const Double_t r2  = fHistSel->GetYaxis()->GetBinLowEdge(iy+1);
+            TAxis *yaxis = fHistSel->GetYaxis();
+
+            const Double_t r1  = yaxis->GetBinLowEdge(iy);
+            const Double_t r2  = yaxis->GetBinLowEdge(iy+1);
 
             const Double_t A   = TMath::Pi() * (r2*r2 - r1*r1);
Index: trunk/MagicSoft/Mars/mmontecarlo/MMcCollectionAreaCalc.cc
===================================================================
--- trunk/MagicSoft/Mars/mmontecarlo/MMcCollectionAreaCalc.cc	(revision 966)
+++ trunk/MagicSoft/Mars/mmontecarlo/MMcCollectionAreaCalc.cc	(revision 967)
@@ -61,5 +61,5 @@
     if (!fMcTrig)
     {
-        *fLog << dbginf << fObjName << " not found... exit." << endl;
+        *fLog << dbginf << fObjName << " [MMcTrig] not found... exit." << endl;
         return kFALSE;
     }
Index: trunk/MagicSoft/Mars/mraw/MRawRunHeader.cc
===================================================================
--- trunk/MagicSoft/Mars/mraw/MRawRunHeader.cc	(revision 966)
+++ trunk/MagicSoft/Mars/mraw/MRawRunHeader.cc	(revision 967)
@@ -94,6 +94,6 @@
     fin.read((Byte_t*)&fProjectName,     22);
     fin.read((Byte_t*)&fSourceName,      12);
-    fin.read((Byte_t*)dummy,              4); // was RA
-    fin.read((Byte_t*)dummy,              4); // was DEC
+    fin.read((Byte_t*)dummy,              4); // was RA  (moved to tracking system)
+    fin.read((Byte_t*)dummy,              4); // was DEC (moved to tracking system)
     fin.read((Byte_t*)&fSourceEpochChar,  2);
     fin.read((Byte_t*)&fSourceEpochDate,  2);
