Index: branches/HeuristicLab.DataAnalysis.Symbolic.LinearInterpreter/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/Interpreter/SymbolicDataAnalysisExpressionTreeLinearInterpreter.cs
===================================================================
--- branches/HeuristicLab.DataAnalysis.Symbolic.LinearInterpreter/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/Interpreter/SymbolicDataAnalysisExpressionTreeLinearInterpreter.cs	(revision 9739)
+++ branches/HeuristicLab.DataAnalysis.Symbolic.LinearInterpreter/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/Interpreter/SymbolicDataAnalysisExpressionTreeLinearInterpreter.cs	(revision 9758)
@@ -32,6 +32,6 @@
 namespace HeuristicLab.Problems.DataAnalysis.Symbolic {
   [StorableClass]
-  [Item("SymbolicDataAnalysisExpressionTreeLinearInterpreter", "Linear (non-recursive) interpreter for symbolic expression trees (does not support ADFs).")]
-  public class SymbolicDataAnalysisExpressionTreeLinearInterpreter : ParameterizedNamedItem, ISymbolicDataAnalysisExpressionTreeInterpreter {
+  [Item("SymbolicDataAnalysisExpressionTreeLinearInterpreter", "Linear (non-recursive) interpreter for symbolic expression trees. This interpreter is faster but does not support Integral, Derivative, TimeLag or ADF function nodes.")]
+  public sealed class SymbolicDataAnalysisExpressionTreeLinearInterpreter : ParameterizedNamedItem, ISymbolicDataAnalysisExpressionTreeInterpreter {
     private const string CheckExpressionsWithIntervalArithmeticParameterName = "CheckExpressionsWithIntervalArithmetic";
     private const string EvaluatedSolutionsParameterName = "EvaluatedSolutions";
@@ -46,5 +46,4 @@
 
     #region parameter properties
-
     public IValueParameter<BoolValue> CheckExpressionsWithIntervalArithmeticParameter {
       get { return (IValueParameter<BoolValue>)Parameters[CheckExpressionsWithIntervalArithmeticParameterName]; }
@@ -54,27 +53,23 @@
       get { return (IValueParameter<IntValue>)Parameters[EvaluatedSolutionsParameterName]; }
     }
-
     #endregion
 
     #region properties
-
     public BoolValue CheckExpressionsWithIntervalArithmetic {
       get { return CheckExpressionsWithIntervalArithmeticParameter.Value; }
       set { CheckExpressionsWithIntervalArithmeticParameter.Value = value; }
     }
-
     public IntValue EvaluatedSolutions {
       get { return EvaluatedSolutionsParameter.Value; }
       set { EvaluatedSolutionsParameter.Value = value; }
     }
-
     #endregion
 
     [StorableConstructor]
-    protected SymbolicDataAnalysisExpressionTreeLinearInterpreter(bool deserializing)
+    private SymbolicDataAnalysisExpressionTreeLinearInterpreter(bool deserializing)
       : base(deserializing) {
     }
 
-    protected SymbolicDataAnalysisExpressionTreeLinearInterpreter(
+    private SymbolicDataAnalysisExpressionTreeLinearInterpreter(
       SymbolicDataAnalysisExpressionTreeLinearInterpreter original, Cloner cloner)
       : base(original, cloner) {
@@ -86,10 +81,10 @@
 
     public SymbolicDataAnalysisExpressionTreeLinearInterpreter()
-      : base("SymbolicDataAnalysisExpressionTreeLinearInterpreter", "Interpreter for symbolic expression trees including automatically defined functions.") {
+      : base("SymbolicDataAnalysisExpressionTreeLinearInterpreter", "Linear (non-recursive) interpreter for symbolic expression trees (does not support ADFs).") {
       Parameters.Add(new ValueParameter<BoolValue>(CheckExpressionsWithIntervalArithmeticParameterName, "Switch that determines if the interpreter checks the validity of expressions with interval arithmetic before evaluating the expression.", new BoolValue(false)));
       Parameters.Add(new ValueParameter<IntValue>(EvaluatedSolutionsParameterName, "A counter for the total number of solutions the interpreter has evaluated", new IntValue(0)));
     }
 
-    protected SymbolicDataAnalysisExpressionTreeLinearInterpreter(string name, string description)
+    private SymbolicDataAnalysisExpressionTreeLinearInterpreter(string name, string description)
       : base(name, description) {
       Parameters.Add(new ValueParameter<BoolValue>(CheckExpressionsWithIntervalArithmeticParameterName, "Switch that determines if the interpreter checks the validity of expressions with interval arithmetic before evaluating the expression.", new BoolValue(false)));
@@ -123,9 +118,9 @@
 
       var code = SymbolicExpressionTreeLinearCompiler.Compile(tree, OpCodes.MapSymbolToOpCode);
-      PrepareInterpreterState(code, dataset);
+      PrepareInstructions(code, dataset);
       return rows.Select(row => Evaluate(dataset, ref row, code));
     }
 
-    private static void PrepareInterpreterState(LinearInstruction[] code, Dataset dataset) {
+    private static void PrepareInstructions(LinearInstruction[] code, Dataset dataset) {
       for (int i = code.Length - 1; i >= 0; --i) {
         var instr = code[i];
@@ -159,7 +154,7 @@
     private static double Evaluate(Dataset dataset, ref int row, LinearInstruction[] code) {
       for (int i = code.Length - 1; i >= 0; --i) {
+        if (code[i].opCode == OpCodes.Constant) continue;
+        #region opcode switch
         var instr = code[i];
-        if (instr.opCode == OpCodes.Constant) continue;
-        #region opcode switch
         switch (instr.opCode) {
           case OpCodes.Variable: {
@@ -241,4 +236,18 @@
           case OpCodes.Tan: {
               instr.value = Math.Tan(code[instr.childIndex].value);
+            }
+            break;
+          case OpCodes.Square: {
+              instr.value = Math.Pow(code[instr.childIndex].value, 2);
+            }
+            break;
+          case OpCodes.Power: {
+              double x = code[instr.childIndex].value;
+              double y = Math.Round(code[instr.childIndex + 1].value);
+              instr.value = Math.Pow(x, y);
+            }
+            break;
+          case OpCodes.SquareRoot: {
+              instr.value = Math.Sqrt(code[instr.childIndex].value);
             }
             break;
@@ -422,18 +431,7 @@
             }
             break;
-          case OpCodes.TimeLag: {
-              throw new NotSupportedException();
-            }
-          case OpCodes.Integral: {
-              throw new NotSupportedException();
-            }
-          case OpCodes.Derivative: {
-              throw new NotSupportedException();
-            }
-          case OpCodes.Arg: {
-              throw new NotSupportedException();
-            }
           default:
-            throw new NotSupportedException();
+            var errorText = string.Format("The {0} symbol is not supported by the linear interpreter. To support this symbol, please use another interpreter.", instr.dynamicNode.Symbol.Name);
+            throw new NotSupportedException(errorText);
         }
         #endregion
