Index: trunk/MagicSoft/Mars/Changelog
===================================================================
--- trunk/MagicSoft/Mars/Changelog	(revision 7521)
+++ trunk/MagicSoft/Mars/Changelog	(revision 7522)
@@ -18,4 +18,12 @@
 
                                                  -*-*- END OF LINE -*-*-
+ 2006/02/23 Thomas Bretz
+
+   * mjobs/MJSpectrum.cc:
+     - fixed plot for Eý.dN/dE. The spectrum was multiplied with two
+       times the bin-width instead of the absolute energy
+
+
+
  2006/02/22 Daniela Dorner
 
Index: trunk/MagicSoft/Mars/NEWS
===================================================================
--- trunk/MagicSoft/Mars/NEWS	(revision 7521)
+++ trunk/MagicSoft/Mars/NEWS	(revision 7522)
@@ -7,4 +7,6 @@
    - ganymed: now stops in requested source isn't found in catalog file
 
+   - ganymed: fixed plot for Eý.dN/dE. The spectrum was multiplied with two
+     times the bin-width instead of the absolute energy
 
 
Index: trunk/MagicSoft/Mars/mjobs/MJSpectrum.cc
===================================================================
--- trunk/MagicSoft/Mars/mjobs/MJSpectrum.cc	(revision 7521)
+++ trunk/MagicSoft/Mars/mjobs/MJSpectrum.cc	(revision 7522)
@@ -700,6 +700,8 @@
     for (int i=0; i<spectrum.GetNbinsX(); i++)
     {
-        spectrum.SetBinContent(i+1, spectrum.GetBinContent(i+1)*spectrum.GetBinWidth(i+1)*spectrum.GetBinWidth(i+1));
-        spectrum.SetBinError(  i+1, spectrum.GetBinError(i+1)  *spectrum.GetBinWidth(i+1)*spectrum.GetBinWidth(i+1));
+        const Double_t e = TMath::Sqrt(spectrum.GetBinLowEdge(i+1)*spectrum.GetBinLowEdge(i+2))*1e-3;
+
+        spectrum.SetBinContent(i+1, spectrum.GetBinContent(i+1)*e*e);
+        spectrum.SetBinError(  i+1, spectrum.GetBinError(i+1)  *e*e);
     }
 
