• No results found

that o f the previous chapter except the following:

• The functions and terminals are monomorphic instead o f polymorphic (see Table 7.1). • Unlike polymorphic f o l d r , which allows a program to contain infinite num ber o f

f o l d r (see Section 6.6.3), the monomorphic f o l d r function can only appear at most twice in a program within the restricted tree depth 4 (see Section 7.3). Consequently, the nested recursion limit o f 100 is not necessary.

• The subtrees representing X abstractions are restricted to a depth limit o f 5. This is the same as that used by Koza to run his Boolean rules experiments (see Section 7.4). • Instead o f selection nodes with bias towards the root nodes (see Section 4.4.1), we allow

each external/internal node in a program tree to have an equal opportunity to be selected for crossover and mutation. Moreover, genetic operations are applied to full application nodes only. This is the normal GP implementation which allows the experiment results to reflect GP performance more accurately.

Figure 7.7 shows the performance curves based on 50 runs.

40000 0.8 30000 0.6 3 to o Z' 20000 0.4 £ X a P i r n • — l(M,l,z) 10000 Q. 0.2 0il55002%) 27 0 10 20 Generation (/> s ■o

F igure 7.7: P erfo rm an ce curves fo r th e general even-parity problem .

Due to the different implementations, the results are different from that in Figure 6.2. In par­ ticular, the probability o f success at generation 0 is 3 times higher (7/50 vs. 2/50) in this experiment. This is a reasonable result based on our analysis in Section 6.8.1. With polymor­ phic implementation, it takes GP about 3 generations to identify the promising area o f the

search space, i.e. that contains programs with 1, 2 or no f o l d r . In contrast, monomorphic implementation allows GP to start with a search space that contains only 1, 2 or no f o l d r . Consequently, the solutions can be found more easily at generation 0 through random search.

All 50 runs find a perfect solution. Among them, 7 runs find a solution at generation 0. The probability o f success curve, P(M,i), starts as 14% at generation 0 and reaches 100% at generation 27. The “effort” curve, l(M,i,z), gives the number o f program evaluations required at each generation to find a solution (see Appendix B). According to the experiment results, a solution to the general e v e n - p a r i t y problem can be found by evaluating 15,500 programs which are randomly generated at generation 0. This is very close to our estimate o f 18,000 program evaluations. Consequently, the 2 implications o f our analysis are asserted.

7.6

Analysis and Discussion

With a program representation which supports structure abstraction, the general e v e n - p a r ­ i t y problem can be solved by random generation o f 15,500 program trees. This result raises two important questions:

• Why structure abstraction makes the general e v e n - p a r i t y an easy problem? • Why random search outperforms GP search on this problem?

We address these two questions in the following subsections.

7.6.1

Impacts of Structure Abstraction

Structure abstraction has enabled the general e v e n - p a r i t y problem to be solved very effi­ ciently. Yet, this problem has a search space (the 7,603 program structures with their X

abstractions expanded with all possible subtrees) which is undoubtedly large. Moreover, the density o f the solution is very low (0.38%). This suggests that the difficulty o f a problem might be independent o f the density o f the solution in the search space. Instead, it relies on how easily these solutions can be found. Our analysis indicates that the effort required to find a solution to the problem is approximately the same as that to find the Boolean rules partial solutions. This means that the module mechanism o f X abstraction, which allows partial solu­ tions to be evolved, is very important to the search o f the solution. However, provided with partial solutions alone, [Langdon and Poli, 1998b] has shown that the generation o f the over­ all solution is still not able to be achieved. An additional ingredient is the method to manipu­ late the partial solutions. The structure abstraction supported by f o l d r provides both ingredients, hence enables the solutions to be found easily:

• The bottom level o f the structure abstraction hierarchy (1 abstraction) supports the evo­ lution o f partial solutions (Boolean rules).

• The top level o f the structure abstraction hierarchy ( f o l d r higher-order function) pro­ vides a mechanism for the manipulation o f the partial solutions (reuse the Boolean rules) and the specification o f the inputs order (as a list).

In other words, structure abstraction provides a mechanism o f hierarchical processing in prob­ lem solving: partial solutions are evolved and manipulated to form a bigger solution. This hierarchical processing is shown to be very effective in solving the general e v e n - p a r i t y problem.

7.6.2

Random Search Versus GP Search

The fitness distribution (Figure 7.6) shows that program structures with fitness 6 occupies more than 60% o f the search space while program structures with other fitness are sparse. This means that the search space contains little gradient information. Like any other progres­ sive search algorithms, GP relies on gradient information to perform search. Without such information, GP is not able to outperform random search on this problem.

However, structure abstraction does not always create this kind o f search space. With dif­ ferent problems, we anticipate that structure abstraction will generate a search space which allows GP to shine.

Related documents