![Page 1: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/1.jpg)
An Introduction to Differential Evolution
Kelly Fleetwood
![Page 2: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/2.jpg)
Synopsis
• Introduction
• Basic Algorithm
• Example
• Performance
• Applications
![Page 3: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/3.jpg)
The Basics of Differential Evolution
• Stochastic, population-based optimisation algorithm
• Introduced by Storn and Price in 1996
• Developed to optimise real parameter, real valued functions
• General problem formulation is:
For an objective function f : X ⊆ RD → R where the feasible regionX 6= ∅, the minimisation problem is to find
x∗ ∈ X such that f(x∗) ≤ f(x) ∀x ∈ X
where:f(x∗) 6= −∞
![Page 4: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/4.jpg)
Why use Differential Evolution?
• Global optimisation is necessary in fields such as engineering, statisticsand finance
• But many practical problems have objective functions that are non-differentiable, non-continuous, non-linear, noisy, flat, multi-dimensionalor have many local minima, constraints or stochasticity
• Such problems are difficult if not impossible to solve analytically
• DE can be used to find approximate solutions to such problems
![Page 5: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/5.jpg)
Evolutionary Algorithms
• DE is an Evolutionary Algorithm
• This class also includes Genetic Algorithms, Evolutionary Strategies andEvolutionary Programming
Mutation Recombination SelectionInitialisation
Figure 1: General Evolutionary Algorithm Procedure
![Page 6: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/6.jpg)
Notation
• Suppose we want to optimise a function with D real parameters
• We must select the size of the population N (it must be at least 4)
• The parameter vectors have the form:
xi,G = [x1,i,G, x2,i,G, . . . xD,i,G] i = 1, 2, . . . , N.
where G is the generation number.
![Page 7: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/7.jpg)
Initialisation
Mutation Recombination SelectionInitialisation
• Define upper and lower bounds for each parameter:
xLj ≤ xj,i,1 ≤ xU
j
• Randomly select the initial parameter values uniformly on the intervals[xL
j , xUj ]
![Page 8: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/8.jpg)
Mutation
Mutation Recombination SelectionInitialisation
• Each of the N parameter vectors undergoes mutation, recombination andselection
• Mutation expands the search space
• For a given parameter vector xi,G randomly select three vectors xr1,G,xr2,G and xr3,G such that the indices i, r1, r2 and r3 are distinct
![Page 9: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/9.jpg)
Mutation
Mutation Recombination SelectionInitialisation
• Add the weighted difference of two of the vectors to the third
vi,G+1 = xr1,G + F (xr2,G − xr3,G)
• The mutation factor F is a constant from [0, 2]
• vi,G+1 is called the donor vector
![Page 10: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/10.jpg)
Recombination
Mutation Recombination SelectionInitialisation
• Recombination incorporates successful solutions from the previous gen-eration
• The trial vector ui,G+1 is developed from the elements of the target vector,xi,G, and the elements of the donor vector, vi,G+1
• Elements of the donor vector enter the trial vector with probability CR
![Page 11: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/11.jpg)
Recombination
Mutation Recombination SelectionInitialisation
uj,i,G+1 =
vj,i,G+1 if randj,i ≤ CR or j = Irand
xj,i,G if randj,i > CR and j 6= Irand
i = 1, 2, . . . , N ; j = 1, 2, . . . , D
• randj,i ∼ U [0, 1], Irand is a random integer from [1, 2, ..., D]
• Irand ensures that vi,G+1 6= xi,G
![Page 12: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/12.jpg)
Selection
Mutation Recombination SelectionInitialisation
• The target vector xi,G is compared with the trial vector vi,G+1 and theone with the lowest function value is admitted to the next generation
xi,G+1 =
ui,G+1 if f(ui,G+1) ≤ f(xi,G)
xi,G otherwisei = 1, 2, . . . , N
• Mutation, recombination and selection continue until some stopping cri-terion is reached
![Page 13: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/13.jpg)
Example: Ackley’s function
• DE with N = 10, F = 0.5 and CR = 0.1
• Ackley’s function
f(x1, x2) = 20+e−20exp
(−0.2
√1n
(x21 + x2
2)
)−exp
(1n
(cos(2πx1) + cos(2πx2)))
• Find x∗ ∈ [−5, 5] such that f(x∗) ≤ f(x) ∀x ∈ [−5, 5]
• f(x∗) = 0; x∗ = (0, 0)
![Page 14: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/14.jpg)
Example: Ackley’s function
−5−4
−3−2 −1
01
23
4 5
−5
0
5
−5
0
5
10
15
x1
x2
f(x)
![Page 15: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/15.jpg)
Example: Ackley’s function
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
0
2
4
6
8
10
12
14
![Page 16: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/16.jpg)
Example: Initialisation
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
![Page 17: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/17.jpg)
Example: Mutation
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
![Page 18: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/18.jpg)
Example: Mutation
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
![Page 19: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/19.jpg)
Example: Mutation
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
![Page 20: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/20.jpg)
Example: Mutation
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
![Page 21: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/21.jpg)
Example: Mutation
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
![Page 22: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/22.jpg)
Example: Recombination
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
![Page 23: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/23.jpg)
Example: Selection
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
![Page 24: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/24.jpg)
Example: Selection
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
![Page 25: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/25.jpg)
Example: Selection
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
![Page 26: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/26.jpg)
Example: Mutation
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
![Page 27: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/27.jpg)
Example: Mutation
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
![Page 28: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/28.jpg)
Example: Mutation
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
![Page 29: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/29.jpg)
Example: Mutation
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
![Page 30: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/30.jpg)
Example: Mutation
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
![Page 31: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/31.jpg)
Example: Recombination
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
![Page 32: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/32.jpg)
Example: Recombination
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
![Page 33: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/33.jpg)
Example: Selection
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
![Page 34: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/34.jpg)
Example: Selection
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
![Page 35: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/35.jpg)
Example: Generation 2
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
![Page 36: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/36.jpg)
Example: Generation 1
−5 −4 −3 −2 −1 0 1 2 3 4 5−5
−4
−3
−2
−1
0
1
2
3
4
5
x1
x 2
![Page 37: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/37.jpg)
Example: Movie
• Thirty generations of DE
• N = 10, F = 0.5 and CR = 0.1
• Ackley’s function
![Page 38: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/38.jpg)
Performance
• There is no proof of convergence for DE
• However it has been shown to be effective on a large range of classicoptimisation problems
• In a comparison by Storn and Price in 1997 DE was more efficient thansimulated annealing and genetic algorithms
• Ali and Torn (2004) found that DE was both more accurate and moreefficient than controlled random search and another genetic algorithm
• In 2004 Lampinen and Storn demonstrated that DE was more accu-rate than several other optimisation methods including four genetic al-gorithms, simulated annealing and evolutionary programming
![Page 39: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/39.jpg)
Recent Applications
• Design of digital filters
• Optimisation of strategies for checkers
• Maximisation of profit in a model of a beef property
• Optimisation of fermentation of alcohol
![Page 40: An Introduction to Differential Evolution · The Basics of Differential Evolution • Stochastic, population-based optimisation algorithm • Introduced by Storn and Price in 1996](https://reader030.vdocuments.mx/reader030/viewer/2022040610/5ed1f60aedd6c962b04ec80c/html5/thumbnails/40.jpg)
Further Reading
• Price, K.V. (1999), ‘An Introduction to Differential Evolution’ in Corne,D., Dorigo, M. and Glover, F. (eds), New Ideas in Optimization, McGraw-Hill, London.
• Storn, R. and Price, K. (1997), ‘Differential Evolution - A Simple and Effi-cient Heuristic for Global Optimization over Continuous Spaces’, Journalof Global Optimization, 11, pp. 341–359.