Index: trunk/MagicSoft/Mars/Changelog
===================================================================
--- trunk/MagicSoft/Mars/Changelog	(revision 6830)
+++ trunk/MagicSoft/Mars/Changelog	(revision 6831)
@@ -32,4 +32,6 @@
      - removed obsolete flag for ModifiedExtractWin
 
+   * mdata/MDataChain.cc:
+     - fixe to allow sign after e (eg. 1e-3, 1e+5 instead of 1e3, 1e5)
 
    * mcalib/MCalibColorSet.cc, mcalib/MCalibrationChargeCalc.cc,
Index: trunk/MagicSoft/Mars/mdata/MDataChain.cc
===================================================================
--- trunk/MagicSoft/Mars/mdata/MDataChain.cc	(revision 6830)
+++ trunk/MagicSoft/Mars/mdata/MDataChain.cc	(revision 6831)
@@ -399,4 +399,7 @@
 void MDataChain::AddParenthesis(TString &test, const TString op) const
 {
+    // Signiture of an exponential number 1e12
+    static const TRegexp rexp("[.0123456789]e[+-][0123456789]");
+
     const TString low = op(1, op.Length());
     if (low.Length()==0)
@@ -425,4 +428,9 @@
             if (cnt>0 || low.First(check[i])<0)
                 continue;
+
+            // Check if operator belongs to an exponential number
+            const TString sub(check(i-2, 4));
+            if (!sub(rexp).IsNull())
+                continue;
             break;
         }
@@ -437,4 +445,9 @@
                 cnt--;
             if (cnt>0 || low.First(check[j])<0)
+                continue;
+
+            // Check if operator belongs to an exponential number
+            const TString sub(check(j-2, 4));
+            if (!sub(rexp).IsNull())
                 continue;
             break;
