# Changeset 10423

Ignore:
Timestamp:
01/29/14 15:02:11 (6 years ago)
Message:

#2026 updated examples

Location:
branches/HeuristicLab.Problems.GPDL/Examples
Files:
2 edited

Unmodified
Added
Removed
• ## branches/HeuristicLab.Problems.GPDL/Examples/OneMaxBinary.txt

 r10415 // special adaptation of the one-max problem // must find maximal number of 1-terminals // optimal solution = 32, number of solutions 2^32 // special adaptation of the one-max problem for tree representations // must find maximal number of 1-terminals (maximum for a limited tree height h is 2 ^ (h - 1) ) // the actual grammar: // E -> 0 | 1 | E E // // leading to example tree: //   E //  / \ // 0   E //    / \ //   1   0 // with a value of 1 // // optimal tree for height = 3 has the value 4 //       E //     /   \ //    E     E //   / \   / \ //  1   1 1   1 // because of constraints of the implemented solvers we have to express the grammar differently // // E -> T | N // N -> E E // T -> A | B     // A has value 0, B has value 1 PROBLEM OneMaxBinary NONTERMINALS S<>. U<>. V<>. W<>. X<>. Y<>. E<>. T<>. N<>. TERMINALS RULES S<> =                                LOCAL << int n1, n2; >> U<> U<>                       SEM << n = n1 + n2; >> . U<> =                                LOCAL << int n1, n2; >> V<> V<>                       SEM << n = n1 + n2; >> . V<> =                                LOCAL << int n1, n2; >> W<> W<>                       SEM << n = n1 + n2; >> . W<> =                                LOCAL << int n1, n2; >> X<> X<>                       SEM << n = n1 + n2; >> . // 2^32 solutions X<> =                                LOCAL << int n1, n2; >> T<> T<>                       SEM << n = n1 + n2; >> E<> = T<> | N<> . // uncomment for 2^64 solutions // X<> =                                LOCAL << int n1, n2; >> //   Y<> Y<>                       SEM << n = n1 + n2; >> // . Y<> =                                LOCAL << int n1, n2; >> T<> T<>                       SEM << n = n1 + n2; >> N<> =                                LOCAL << int n1, n2; >> E<> E<>                       SEM << n = n1 + n2; >> . T<> = A                                             SEM << n = 1; >> | B                                           SEM << n = 0; >> A                                             SEM << n = 0; >> | B                                           SEM << n = 1; >> . << int n; S(out n); E(out n); return (double) n; >>
• ## branches/HeuristicLab.Problems.GPDL/Examples/RoyalTree.txt

 r10080 /* The Royal Tree benchmark problem for GP */ /* See paper: William F. Punch, How Effective are Multiple Populations in Genetic Programming */ /* for max. depth 7 (level: g) this is hard to solve. Full enumeration needs a lot of memory. */ /* for max. depth 7 (level: g) this is hard to solve. */ PROBLEM RoyalTree
Note: See TracChangeset for help on using the changeset viewer.