Читать книгу Power Magnetic Devices - Scott D. Sudhoff - Страница 25

Crossover

Оглавление

In the case of the canonical GA, crossover is accomplished by breaking the subject chromosomes of the parents at the same point and interchanging them to form the corresponding chromosomes of the children. This interchange substantially alters the gene where the chromosome is interchanged, and it results in an interchange of genes falling after the interchange point.

There are several algorithms to achieve crossover in real‐coded GAs. One of them is single‐point crossover, which can be readily generalized to n‐point crossover. This method is straightforward and is readily illustrated by the example shown in Figure 1.10. Therein, the genetic code for two parents, θp1 and θp2, is shown. Observe that the elements of these vectors are real numbers in the domain [0,1]. In this algorithm, a crossover point is chosen at random and the genes after the crossover points are interchanged (these genes are in bold) to form two new genetic codes, θa1 and θa2, which will become children after the application of additional genetic operators such as mutation.

Single‐point crossover is very similar to biological crossover. However, note that gene values cannot become altered using this operator. This limits the amount of genetic diversity that can be brought about.

Simple‐blend crossover can be used to increase the genetic diversity. Let us consider the jth gene of parents θp1 and θp2. If the jth gene is being crossed over, the new gene values are determined by first computing a random number υ given by

(1.6-5)

where U(·) denotes a random number generator that generates a uniformly distributed random number in the range [0,1]. Next, the gene values of the children are set to

(1.6-6)

(1.6-7)

where α is an algorithm constant often taken to be 0.5. Observe that in this algorithm the average gene value for the children is the same as for the parents. Canonical GAs also have this property.

Another commonly used crossover algorithm is simulated binary crossover. This algorithm is designed to yield results that would be similar to those obtained by crossover within a gene using the canonical GA. These properties include the fact that the sum of the gene values is the same for the children as the parents and that the children tend to be similar to the parents (which is also the case in simple‐blend crossover). In this algorithm, first a random number in [0,1) is computed as in (1.6-5) from which a factor β is computed as


Figure 1.10 Single‐point crossover.

(1.6-8)

In (1.6-8), ηc is an algorithm parameter. Once β is found, the genes of the children are computed as

(1.6-9)

(1.6-10)

In both simple blend and simulated binary crossover, it is possible to generate gene values outside of [0,1]. For example, suppose the parent gene values are 0.5 and 1, and we use simple‐blend crossover with α = 0.8. Further, suppose υ = 0.9. The resulting gene values for the children would be 0.39 and 1.11, the latter of which is outside the allowed set of values. In this case, gene repair becomes necessary. There are several approaches to this. Hard limiting the gene values is one approach. For example, a gene value calculated as 1.2 is simply represented as 1.0. Similarly, a gene value of −2.1 would be set to 0. Alternately, gene values can be ring mapped, which is to say corrected using a modulus 1 operator. In this case, 1.2 would be repaired to 0.2 and −2.1 would be repaired to 0.9. For integer‐coded genes, additional repair is necessary in order to make sure that the gene values take on allowed values.

Our discussion of simple blend and simulated binary crossover has focused at the gene level, and so it is now appropriate to consider the application of these processes at the chromosome level. There are several approaches that could be taken. In scalar crossover, each gene in a chromosome that is being operated upon undergoes a crossover operation independently. Each gene in a chromosome uses a different υ. In vector crossover, υ is the same for all genes in a crossover. This leads to scalar simple‐blend crossover, vector simple‐blend crossover, scalar simulated binary crossover, and vector simulated binary crossover.

As can be seen, it is perhaps too easy to create new genetic operators. However, before leaving the topic, one final combination will be considered, namely, single‐point simple‐blend crossover. In this algorithm, a single gene of the chromosome is selected as a crossover point. Unlike single‐point crossover, however, the crossover point is a gene, not a position between genes. That gene is operated upon with the simple blend operator. The remaining genes are interchanged as in single‐point crossover. The process is illustrated in Figure 1.11. Therein, the third gene is randomly selected as the crossover point, α is taken as 0.5, and υ was 0.81 (determined at random). Single‐point simple‐blend crossover is somewhat similar to the inheritance of quantitative traits wherein multiple genes are involved in determining the extent of an attribute. One could also devise single‐point simulated binary crossover or multipoint simple‐blend crossovers in a straightforward fashion.


Figure 1.11 Single‐point simple‐blend crossover.

Power Magnetic Devices

Подняться наверх