Changeset 4459 for branches/DataAnalysis/HeuristicLab.Problems.DataAnalysis/3.3/Tests/SymbolicSimplifierTest.cs
- Timestamp:
- 09/21/10 14:12:27 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/DataAnalysis/HeuristicLab.Problems.DataAnalysis/3.3/Tests/SymbolicSimplifierTest.cs
r4237 r4459 40 40 [TestClass()] 41 41 public class SymbolicSimplifierTest { 42 [TestMethod()]43 42 [DeploymentItem(@"RegressionSolution01.hl")] 44 43 [DeploymentItem(@"RegressionSolution02.hl")] … … 47 46 [DeploymentItem(@"RegressionSolution05.hl")] 48 47 [DeploymentItem(@"RegressionSolution06.hl")] 48 [TestMethod] 49 49 public void SimplifyRegressionSolutionsTest() { 50 50 ContentManager.Initialize(new PersistenceContentManager()); … … 98 98 private SymbolicRegressionSolution SimplifySolution(SymbolicRegressionSolution original) { 99 99 SymbolicSimplifier simplifier = new SymbolicSimplifier(); 100 SymbolicExpressionTree simplifiedExpression = simplifier.Simplify(original.Model.SymbolicExpressionTree); 101 SymbolicExpressionTreeNode root = new ProgramRootSymbol().CreateTreeNode(); 102 SymbolicExpressionTreeNode start = new StartSymbol().CreateTreeNode(); 103 root.AddSubTree(start); 104 start.AddSubTree(simplifiedExpression.Root); 105 SymbolicExpressionTree simplifiedTree = new SymbolicExpressionTree(root); 100 SymbolicExpressionTree simplifiedTree = simplifier.Simplify(original.Model.SymbolicExpressionTree); 106 101 SymbolicRegressionModel simplifiedModel = new SymbolicRegressionModel(original.Model.Interpreter, simplifiedTree); 107 102 return new SymbolicRegressionSolution(original.ProblemData, simplifiedModel, original.LowerEstimationLimit, original.UpperEstimationLimit);
Note: See TracChangeset
for help on using the changeset viewer.