Changeset 4226 for branches/DataAnalysis
- Timestamp:
- 08/16/10 10:08:29 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/DataAnalysis/HeuristicLab.Problems.DataAnalysis/3.3/Symbolic/SymbolicSimplifier.cs
r4220 r4226 114 114 return original.Symbol is Logarithm; 115 115 } 116 private bool IsIfThenElse(SymbolicExpressionTreeNode original) { 117 return original.Symbol is IfThenElse; 118 } 116 119 #endregion 117 120 … … 135 138 return SimplifyAverage(original); 136 139 } else if (IsLog(original)) { 137 // TODO simplify logarditm 140 // TODO simplify logarithm 141 return SimplifyAny(original); 142 } else if (IsIfThenElse(original)) { 143 // TODO simplify conditionals 138 144 return SimplifyAny(original); 139 145 } else if (IsAverage(original)) { … … 238 244 239 245 #region low level tree restructuring 240 // each make* method must return asimplified tree246 // MakeFraction, MakeProduct and MakeSum take two already simplified trees and create a new simplified tree 241 247 242 248 private SymbolicExpressionTreeNode MakeFraction(SymbolicExpressionTreeNode a, SymbolicExpressionTreeNode b) { … … 341 347 } 342 348 349 // makes sure variable symbols in sums are combined 350 // possible improvment: combine sums of products where the products only reference the same variable 343 351 private void MergeVariablesInSum(SymbolicExpressionTreeNode sum) { 344 352 var subtrees = new List<SymbolicExpressionTreeNode>(sum.SubTrees); … … 415 423 #endregion 416 424 425 // helper to combine the constant factors in products and to combine variables (powers of 2, 3...) 417 426 private void MergeVariablesAndConstantsInProduct(SymbolicExpressionTreeNode prod) { 418 427 var subtrees = new List<SymbolicExpressionTreeNode>(prod.SubTrees);
Note: See TracChangeset
for help on using the changeset viewer.