Changeset 11747 for branches/HeuristicLab.Problems.GrammaticalOptimization/HeuristicLab.Problems.GrammaticalOptimization.SymbReg
- Timestamp:
- 01/12/15 21:23:01 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HeuristicLab.Problems.GrammaticalOptimization/HeuristicLab.Problems.GrammaticalOptimization.SymbReg/SymbolicRegressionProblem.cs
r11742 r11747 75 75 // right now only + and * is supported 76 76 public string CanonicalRepresentation(string terminalPhrase) { 77 return terminalPhrase;78 //var terms = terminalPhrase.Split('+');79 //return string.Join("+", terms.Select(term => string.Join("", term.Replace("*", "").OrderBy(ch => ch)))80 //.OrderBy(term => term));77 //return terminalPhrase; 78 var terms = terminalPhrase.Split('+'); 79 return string.Join("+", terms.Select(term => string.Join("", term.Replace("*", "").OrderBy(ch => ch))) 80 .OrderBy(term => term)); 81 81 } 82 82 }
Note: See TracChangeset
for help on using the changeset viewer.