Information Technology Reference
In-Depth Information
14.3.1 Generation of the Initial Population
The algorithm starts with the random generation of an initial set of candidate
solutions, the initial population . If there is some prior knowledge about the posi-
tion of the solution into the search space, it can be used in this step. Each element in
the population is called an individual or chromosome , consisting of a vector contain-
ing the parameters to be optimized. Each parameter is called a gene . In this work,
each chromosome is a vector of nine real numbers between
100 and 100, each one
corresponding to the constant value in the consequent of a rule of the fuzzy controller.
The number of chromosomes in the population must be manually set, depending
on the dimension of the search space. Too small a number can produce a premature
convergence to a local optimum, because it does not allow the search throughout the
full space of solutions. In contrast, too big a number slows down the algorithm and
increases the computational resources necessary. The minimum number of chro-
mosomes in the population should be at least twice the number of genes in each
chromosome. In the present work a random initial population of 36 individuals was
created.
14.3.2 Evaluation of the Initial Population
Each one of the chromosomes in the current population is evaluated by a real function,
called the fitness function , expressing the degree of goodness in solving the problem.
This real function is problem dependent, and its selection can be the most difficult
task, because the other ones are more or less standard. In the simplest cases, the
objective function (the function that must be maximized or minimized) or some
other function directly related can be used. In more complex cases the evaluation of
an individual is not so easy, as in the present case, which requires a simulation to be
run and then the results to be processed.
In this work, the goal is to minimize a cost function. To evaluate a chromosome,
its genes are taken as consequent terms in the fuzzy controller, and a simulation is
run. Then, the cost J of this chromosome is:
0
N samp
1
T 2
5 |
d sat i
d s i | (
1
+ (
d sat i
<
d s i ))
5 |
accel i |
100
J
=
.
+
0
.
(14.20)
15
i
=
1
The variables in this expression are:
T : total time simulated. In general T
300 s, but the simulation can finish before
this time if there is a collision between cars.
=
d sat : distance between vehicles, provided by the sensory system.
d s : safety distance, which in this example is defined as the distance travelled by
the controlled car in a second, at its present speed:
Search WWH ::




Custom Search