Index: trunk/MagicSoft/Mars/manalysis/AnalysisLinkDef.h
===================================================================
--- trunk/MagicSoft/Mars/manalysis/AnalysisLinkDef.h	(revision 1509)
+++ trunk/MagicSoft/Mars/manalysis/AnalysisLinkDef.h	(revision 1524)
@@ -36,4 +36,7 @@
 #pragma link C++ class MEnergyEst+;
 #pragma link C++ class MEnergyEstimate+;
+#pragma link C++ class MEnergyEstParam+;
+
+#pragma link C++ class MMatrixLoop+;
 
 #pragma link C++ class MPedCalcPedRun+;
Index: trunk/MagicSoft/Mars/manalysis/MEnergyEst.h
===================================================================
--- trunk/MagicSoft/Mars/manalysis/MEnergyEst.h	(revision 1509)
+++ trunk/MagicSoft/Mars/manalysis/MEnergyEst.h	(revision 1524)
@@ -10,4 +10,5 @@
 private:
     Double_t fEnergy; // [GeV] Estimated Energy
+    Double_t fImpact; // [cm]  Estimated Impact
 
 public:
@@ -15,7 +16,11 @@
 
     void SetEnergy(Double_t e) { fEnergy = e; }
+    void SetImpact(Double_t i) { fImpact = i; }
     Double_t GetEnergy() const { return fEnergy; }
+    Double_t GetImpact() const { return fImpact; }
 
-    ClassDef(MEnergyEst, 1) // Storage Container for the estimated Energy
+    void Print(Option_t *o="") const;
+
+    ClassDef(MEnergyEst, 0) // Storage Container for the estimated Energy
 };
 
Index: trunk/MagicSoft/Mars/manalysis/MHillas.cc
===================================================================
--- trunk/MagicSoft/Mars/manalysis/MHillas.cc	(revision 1509)
+++ trunk/MagicSoft/Mars/manalysis/MHillas.cc	(revision 1524)
@@ -55,4 +55,5 @@
 #include <fstream.h>
 
+#include <TArrayF.h>
 #include <TEllipse.h>
 
@@ -78,5 +79,4 @@
 
     Reset();
-    // FIXME: (intelligent) initialization of values missing
 
     fEllipse = new TEllipse;
@@ -380,4 +380,26 @@
 // --------------------------------------------------------------------------
 //
+// This function is ment for special usage, please never try to set
+// values via this function
+//
+void MHillas::Set(const TArrayF &arr)
+{
+    if (arr.GetSize() != 8)
+        return;
+
+    fLength = arr.At(0);  // [mm]        major axis of ellipse
+    fWidth  = arr.At(1);  // [mm]        minor axis of ellipse
+    fDelta  = arr.At(2);  // [rad]       angle of major axis with x-axis
+    fSize   = arr.At(3);  // [#CerPhot]  sum of content of all pixels (number of Cherenkov photons)
+    fMeanX  = arr.At(4);  // [mm]        x-coordinate of center of ellipse
+    fMeanY  = arr.At(5);  // [mm]        y-coordinate of center of ellipse
+
+    fNumUsedPixels = (Short_t)arr.At(6); // Number of pixels which survived the image cleaning
+    fNumCorePixels = (Short_t)arr.At(7); // number of core pixels
+}
+
+
+// --------------------------------------------------------------------------
+//
 /*
 void MHillas::AsciiRead(ifstream &fin)
Index: trunk/MagicSoft/Mars/manalysis/MHillas.h
===================================================================
--- trunk/MagicSoft/Mars/manalysis/MHillas.h	(revision 1509)
+++ trunk/MagicSoft/Mars/manalysis/MHillas.h	(revision 1524)
@@ -6,4 +6,5 @@
 #endif
 
+class TArrayF;
 class TEllipse;
 
@@ -62,4 +63,6 @@
     Int_t GetNumCorePixels() const { return fNumCorePixels; }
 
+    virtual void Set(const TArrayF &arr);
+
     //virtual void AsciiRead(ifstream &fin);
     //virtual void AsciiWrite(ofstream &fout) const;
Index: trunk/MagicSoft/Mars/manalysis/MHillasExt.cc
===================================================================
--- trunk/MagicSoft/Mars/manalysis/MHillasExt.cc	(revision 1509)
+++ trunk/MagicSoft/Mars/manalysis/MHillasExt.cc	(revision 1524)
@@ -37,6 +37,4 @@
 // fM3Long   third moment along major axis
 // fM3Trans  third moment along minor axis
-// fLeakage1 ratio : (photons in most outer ring of pixels) over fSize
-// fLeakage2 ratio : (photons in the 2 outer rings of pixels) over fSize
 //
 // WARNING: Before you can use fAsym, fM3Long and fM3Trans you must
@@ -45,4 +43,7 @@
 ////////////////////////////////////////////////////////////////////////////
 /*
+ // fLeakage1 ratio : (photons in most outer ring of pixels) over fSize
+ // fLeakage2 ratio : (photons in the 2 outer rings of pixels) over fSize
+ //
  // fAsymna   d/(d na) of ( sum(x*q^na)/sum(q^na), sum(y*q^na)/sum(q^na) )
  //           projected onto the major axis
@@ -52,4 +53,5 @@
 
 #include <fstream.h>
+#include <TArrayF.h>
 
 #include "MGeomPix.h"
@@ -238,4 +240,25 @@
 }
 
+// --------------------------------------------------------------------------
+//
+// This function is ment for special usage, please never try to set
+// values via this function
+//
+void MHillasExt::Set(const TArrayF &arr)
+{
+    if (arr.GetSize() != 13)
+        return;
+
+    fConc    = arr.At(8);  // [ratio] concentration ratio: sum of the two highest pixels / fSize
+    fConc1   = arr.At(9);  // [ratio] concentration ratio: sum of the highest pixel / fSize
+    fAsym    = arr.At(10); // [mm]    fDist minus dist: center of ellipse, highest pixel
+    fM3Long  = arr.At(11); // [mm]    3rd moment (e-weighted) along major axis
+    fM3Trans = arr.At(12); // [mm]    3rd moment (e-weighted) along minor axis
+
+    TArrayF n(arr);
+    n.Set(8);
+    MHillas::Set(n);
+}
+
 /*
 // -------------------------------------------------------------------------
Index: trunk/MagicSoft/Mars/manalysis/MHillasExt.h
===================================================================
--- trunk/MagicSoft/Mars/manalysis/MHillasExt.h	(revision 1509)
+++ trunk/MagicSoft/Mars/manalysis/MHillasExt.h	(revision 1524)
@@ -34,4 +34,6 @@
     void Print(Option_t *opt=NULL) const;
 
+    void Set(const TArrayF &arr);
+
     //void AsciiRead(ifstream &fin);
     //void AsciiWrite(ofstream &fout) const;
Index: trunk/MagicSoft/Mars/manalysis/MHillasSrc.cc
===================================================================
--- trunk/MagicSoft/Mars/manalysis/MHillasSrc.cc	(revision 1509)
+++ trunk/MagicSoft/Mars/manalysis/MHillasSrc.cc	(revision 1524)
@@ -54,4 +54,5 @@
 
 #include <fstream.h>
+#include <TArrayF.h>
 
 #include "MLog.h"
@@ -141,4 +142,19 @@
     *fLog << " - CosDeltaAlpha       = " << fCosDeltaAlpha << endl;
 }
+// --------------------------------------------------------------------------
+//
+// This function is ment for special usage, please never try to set
+// values via this function
+//
+void MHillasSrc::Set(const TArrayF &arr)
+{
+    if (arr.GetSize() != 4)
+        return;
+
+    fAlpha = arr.At(0);         // [deg]  angle of major axis with vector to src
+    fDist  = arr.At(1);         // [mm]   distance between src and center of ellipse
+    fHeadTail  = arr.At(2);     // [mm]
+    fCosDeltaAlpha = arr.At(3); // [1]    cosine of angle between d and a
+}
 
 // -----------------------------------------------------------------------
Index: trunk/MagicSoft/Mars/manalysis/MHillasSrc.h
===================================================================
--- trunk/MagicSoft/Mars/manalysis/MHillasSrc.h	(revision 1509)
+++ trunk/MagicSoft/Mars/manalysis/MHillasSrc.h	(revision 1524)
@@ -42,4 +42,6 @@
     virtual Bool_t Calc(const MHillas *hillas);
 
+    void Set(const TArrayF &arr);
+
     //virtual void AsciiRead(ifstream &fin);
     //virtual void AsciiWrite(ofstream &fout) const;
Index: trunk/MagicSoft/Mars/manalysis/Makefile
===================================================================
--- trunk/MagicSoft/Mars/manalysis/Makefile	(revision 1509)
+++ trunk/MagicSoft/Mars/manalysis/Makefile	(revision 1524)
@@ -36,7 +36,9 @@
            MEnergyEst.cc \
            MEnergyEstimate.cc \
+           MEnergyEstParam.cc \
            MSrcPosCam.cc \
            MCameraSmooth.cc \
            MHadroness.cc \
+           MMatrixLoop.cc \
            MCompProbCalc.cc \
            MMultiDimDistCalc.cc \
