how powerful is your evolutionary algorithm

36
How Powerful Is Your Evolutionary Algorithm Xin Yao a ([email protected]) The Center of Excellence for Research in Computational Intelligence and Applications (CERCIA) and Natural Computation Group The University of Birmingham Egbaston, Birmingham, U.K. http://www.cercia.ac.uk a Joint work with Dr. Jun He. – p.1

Upload: others

Post on 01-Dec-2021

7 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: How Powerful Is Your Evolutionary Algorithm

How Powerful Is Your Evolutionary Algorithm

Xin Yao a ([email protected])

The Center of Excellence for Research in Computational Intelligence and Applications

(CERCIA)

and

Natural Computation Group

The University of Birmingham

Egbaston, Birmingham, U.K.

http://www.cercia.ac.uk

aJoint work with Dr. Jun He.

– p.1

Page 2: How Powerful Is Your Evolutionary Algorithm

The Answer

Very Powerful and Efficient!

– p.2

Page 3: How Powerful Is Your Evolutionary Algorithm

Evidences

Actual quotes from published papers:

“A GA is applied to solve a maximum flow problem ...”

“We use a GA to produce very high quality solutions tothe travelling salesman problem”

“The results indicate that the proposed algorithm isable to arrive at high quality solution in a relatively shorttime”

“We describe results computing approximate solutionsto Set Partitioning Problems using GAs”

Note: Boldface added by XY.

– p.3

Page 4: How Powerful Is Your Evolutionary Algorithm

Here Comes the ‘Trouble’

Most likely to be one of your colleagues in the samedepartment, who is envious of your visit to Hawaii(CEC’02), Canberra (CEC’03), � � � , and Edinburgh(CEC’05).

“Hmmm ... Evolutionary algorithms?! Aren’t they justsome random algorithms for people who can’t thinkdeterministically?

... how can a random algorithm that produces adifferent result every time it runs possibly work?”

Note: The characters described in this film (slide) is entirely

fictional.

– p.4

Page 5: How Powerful Is Your Evolutionary Algorithm

Back to Reality

Although theory has been lagging behind practice inevolutionary computation, there have been progressesrecently, e.g., 29 papers in “Theory of EvolutionaryComputation” sessions at CEC’04 and several highly citedtheory papers in IEEE Transactions on EvolutionaryComputation.

One thread of the theoretical work:

Convergence,

Convergence Rate,

Computational Complexity (Scalability): therelationship between computation time and theproblem size.

– p.5

Page 6: How Powerful Is Your Evolutionary Algorithm

Computational Complexity

The ‘Trouble’: “I know. I know. It’s that big-O thing, isn’tit? ...”

Unlike the analysis of deterministic algorithms, which isusually about the worst case, we need to consider themean (average) of the first hitting time in our case.

Many existing tools used in analysing complexity aredifficult to be applied to evolutionary algorithms.

We need ‘new’ analytical tools and a unified frameworkfor analysing different EAs for different problems, andfor convergence, computation time, characterisation ofEA-hardness/-easiness, ...

– p.6

Page 7: How Powerful Is Your Evolutionary Algorithm

Outline

Analytical Tools and Approaches

Drift Analysis

Convergence of EAs

Computation Time of EAs

Why Populations

Characteristics of EA-Easy/-Hard Problems

Discussions and Conclusions

– p.7

Page 8: How Powerful Is Your Evolutionary Algorithm

Popular Approaches

Markov chain Approach: a widely used approach tomodel the behavior of EAs.

A population = a state in the state (probability)space.Generation of a new population = state (probability)transitionPopulations sequence

� ��� �� � ��

� � � �

= a Markovchain.

Convergence: Some good results have been obtained.

Convergence rate: Relatively few results in comparisonwith convergence.

– p.8

Page 9: How Powerful Is Your Evolutionary Algorithm

Markov Chain Approach to Computation time

Let � ������ �

be the first hitting time to optimal solutionswhen starting from a non-optimal population

;

�is the

transition probability matrix written in the form:

� �

� � �

where

is the unit matrix, then the first hitting timesatisfies (He and Yao, 2003) a

� �� � � � � ��

The above linear system is not easy to solve directlyand analytically.

aJ. He and X. Yao. “Towards an analytic framework for analysing the compu-

tation time of evolutionary algorithms.” Art. Intell. 145(1-2):59-97, 2003.– p.9

Page 10: How Powerful Is Your Evolutionary Algorithm

Less Popular but More Useful Approaches

Martingale Approach: less commonly used, but seemsto be more useful and powerful analytical tools to us.

A stochastic process

��� �� � ��

� � � �

is called amartingale, if1. Expectation

� ���� � � ��

� � �, � �

,2. Expectation

� ���� � � ��

�� �� ,

� �.

A super-martingale is defined similarly, except (2) isreplaced by

� ���� � � ��

��� �� �

� ��

A sub-martingale is defined with (2) is replaced by

� ���� � � ��

� �� �

� ��

– p.10

Page 11: How Powerful Is Your Evolutionary Algorithm

Super-martingale for EAs

Define a distance function

� ��� �

to measure how goodor how far a population � is from the optimal solution;

If the mean local performance at each generation:

� � � � ��

� � � � �� � � � � ��

then the sequence

� � � ��

� � � � ��

� � � �

�is a

super-martingale;

Martingale theory can be used to analyseconvergence, mean first hitting time, EA-hardness, ...

– p.11

Page 12: How Powerful Is Your Evolutionary Algorithm

How? Drift Analysis as a General Framework

Consider the population sequence

� �� �� � ��

� � � � �

��

on aprobability space, the general approach to analysing EAsusing drift analysis can be summarised as follows:

Define a distance function

� ��� �

to measure the distancebetween a population � and the optimal solution.

Estimate the one-step mean drift of

�� towards the

optimal solution:

� � � � ��

� � � � ��� � � �

Derive some properties of the sequence, e.g., the firsthitting time, convergence, convergence rate, etc.,through the mean drift.

– p.12

Page 13: How Powerful Is Your Evolutionary Algorithm

An Example: Conference Dinner

XY walks from the dinning room to his bedroom.The dinning room is � meters away from thebedroom.XY always moves forward 1m in each step.

Question: how many steps does XY need to reach hisbedroom?

– p.13

Page 14: How Powerful Is Your Evolutionary Algorithm

Simple and Correct Answer

steps!

– p.14

Page 15: How Powerful Is Your Evolutionary Algorithm

Making Simple Things Complicated

Define a distance function to measure the distancebetween a point � and the bedroom,

� ��� �� � � � � � �� � � � �

��

Estimate the ‘speed’ (drift) (

�� is his position at

-step):

� � ��

� � � � �� � � � �

��

�� � ��

�� � � � � � �

��

Then the first hitting time � to the bedroom:

� �

� ��� ��� �

��� �� � � ��

– p.15

Page 16: How Powerful Is Your Evolutionary Algorithm

An Example: After a Few Drinks

The impact of the few drinks:

At the bar, he always leaves for the bedroom;In between the dinning room and bedroom, hemoves 1 meter in each step, forward with probability0.6, backward with probability 0.4.

Question: how many steps does he need to go to hisbedroom?

– p.16

Page 17: How Powerful Is Your Evolutionary Algorithm

Getting Back After a Few Drinks

Define the same distance function

� ��� �� � .

Estimate his speed (drift) (

�� is his position at

-step):

� � ��

�� � � �� � � � �

��

� if

�� � � �

� if

� � �� � �� with probability

��

��

� � if

� � �� � �� with probability

��

��

Compute the mean speed/drift before arriving at thebedroom:

� � � � ��

� � � � �� � � � � �

� � � ��

� � � ��

��

The mean first hitting time to the bedroom is:

�� � �� ��� ��

� � ��

– p.17

Page 18: How Powerful Is Your Evolutionary Algorithm

An Example: Too Many Drinks

After drink situation:He always heads towards his bedroom.In between the dinning room and the bedroom, hemoves 1 meter in each step, forward with probability0.4 and backward with probability 0.6.

Question: how many steps does he need to arrive athis bedroom?

– p.18

Page 19: How Powerful Is Your Evolutionary Algorithm

Journey Towards the Bedroom

Define a new distance function:

� �� ��

��

� � ��

�� � �

�� ���

� � � � � � � �

��

Speed/drift in between the dinning room and bedroom(

�� � � is his position at

-step),

� � ��

� � � � �� � � � �

�� � �� with probability

��

��

� �

�� � � �� � �� with probability

��

��

Mean speed/drift before arriving at his bedroom:

� � � � ��

�� � � �� � � � � �

� � �

�� � �� ��

� � �

� � � � �� � �

� ��

The mean first hitting time � to home:� �� � �� � �

�� ���

– p.19

Page 20: How Powerful Is Your Evolutionary Algorithm

Summary from the Examples

Given a problem and an EA, we can analyse the EA asfollows:

Define a distance function to measure how far or howgood a population is away from the optimal solution;

Estimate the mean drift towards the optimal solution;

Prove the convergence, convergence rate,computation time, ...

– p.20

Page 21: How Powerful Is Your Evolutionary Algorithm

Convergence

Rudolph’s work in 1994 a

Let

�� be the

-th generation population. Define adistance based on the fitness function� ��� �

��� �� � � ��� ��

If the following drift conditions hold:for any

� � ��

� � �

:

� � � � ��

� � � � �� � � � � ��

� � � � �

with � � � � ��

and�� � � � � � ��

then the stochastic process converges:

� �� � � � ��

� �� � �

aG. Rudolph, “Convergence of Non-elitist Strategies,” in Proc. of the First

IEEE conference on Evolutionary Computation, 63-66, 1994.– p.21

Page 22: How Powerful Is Your Evolutionary Algorithm

Computation time: General Result

Given a combinatorial optimisation problem and an EA (Heand Yao 2001) a

Define the first hitting time to the optimal solution as

� � � � � � � � � � ��

�� � � � ��

If the following drift condition holds:for

�� is not an optimal solution,

���

� � � � ��

� � � � �� � � � � ���

where

��� and

� � are positives.then

� � � ��� ��

� � �� � � ���� � � � �� � ���

aJ. He and X. Yao. Drift analysis and average time complexity of evolutionary

algorithms. Artificial Intelligence, 127 (1):57-85, 2001. (Erratum in Artificial

Intelligence, 140(1):245-248, 2002)) – p.22

Page 23: How Powerful Is Your Evolutionary Algorithm

Computation Time: An Example

An application of the general result to the linear function(first considered by Droste et al. 1998): a

� ��� ��

�� � � �� � � � where � � � ��� � � � � � �� are positives. � � arebits in binary strings of length �.

A

� � �

EA:

Mutation flip each bit in th binary string with probability

� �.

Selection If

� � � ��� �

� � � � ��

, then let�� � � �� ��� �

� , otherwise,let

��� � ��� .

aS. Droste, T. Jansen and I. Wegener. A Rigorous Complexity Analysis of

the (1+1) Evolutionary Algorithm for Linear Functions with Boolean Inputs. Evo-

lutionary Computation 6(2): 185–196, 1998.

– p.23

Page 24: How Powerful Is Your Evolutionary Algorithm

Computation Time: Results from the Example

Assume � is an even integer (He and Yao 2004).a Define

� ��� �� � � � � �

� � �� � �

� � � � � � ��

� �� � � � �� � � � � ��

where � � � �� � �

is a constant.

The mean drift:

� � � � ���

� � � � ��� � � � � �� � �� � � where � is a

positive constant.

The first hitting time:

� �� � � ��� �� � � ��� � �

� � ��� � � � � �

� � � � � ��

aJ. He and X. Yao. A Study of Drift Analysis for Estimating Computation Time

of Evolutionary Algorithms. Natural Computing, 3(1):21-35, 2004. – p.24

Page 25: How Powerful Is Your Evolutionary Algorithm

Wait a Minute!

One of the key characteristics of EAs is their populations.What about population-based EAs?

Computational complexity: will the time complexity bechanged if we introduce a population into EAs?

First hitting probability: which one between an

� � � � �

EA and a

� � �

has a lower failure probability to hitthe optimal solution.

First hitting time to the optimal solution: whether themean first hitting time of an

� � � � �

EA would beshorter than that of a

� � �EA that uses the same

mutation operator and, if it is, how much shorter?

In our work: same mutation in the

� � � EA and the

� � � � �

EA; but different selection.

– p.25

Page 26: How Powerful Is Your Evolutionary Algorithm

Population Can Help

A case study on comparing time complexity: populationcan be beneficial (He and Yao, 2002)) a

Given a problem:

� ��� ��

� � � ��

� �� � � � � �� if

�� � � � � is even�

� � � ��

� �� � � � � � � �� if

�� � � � � is odd�

A

� � �

EA:

� �� ��

� ��� � � � � � ��

� � �.

An

� � � � �

EA:

� �� ��

� � � ��� � ��

.aJ. He and X. Yao. From an Individual to a Population: An Analysis of the First

Hitting Time of Population-Based Evolutionary Algorithms, IEEE Trans. Evo.

Comp. 6(5):495-511, 2002.

– p.26

Page 27: How Powerful Is Your Evolutionary Algorithm

But Not Always

A case study on comparing time complexity: populationmay not be beneficial (He and Yao, 2002)) a

Given a problem

� ��� ��

� � � ��

� �� � � � � � � ��� �� if

�� � � � � � �� �

� � � ��

� �� � � � � �� otherwise �

A

� � �

EA:

� �� ��

� � �� �

.

An

� � � � �

EA:

� �� ��

� � ��� � � � � � � � � � � �

.aJ. He and X. Yao. From an Individual to a Population: An Analysis of the First

Hitting Time of Population-Based Evolutionary Algorithms, IEEE Trans. Evo.

Comp. 6(5):495-511, 2002.

– p.27

Page 28: How Powerful Is Your Evolutionary Algorithm

Characterising Problems for EAs

OK, OK, you’ve made your points. Drift analysis can beuseful to analyse EAs, some of which may be moreefficient than others, but

How do I know whether I should use a given EA for aparticular problem?

In other words, how to characterise problems for EAs?

– p.28

Page 29: How Powerful Is Your Evolutionary Algorithm

EA-Hardness

Given an EA, optimization problems can be divided intotwo classes based on the mean number of generations(first hitting time, to be more accurate) needed to solve theproblems.

EA-Easy Class: For the given EA, starting from any initialpopulation

� � , the mean number of generations neededby the EA to solve the problem, i.e.,

� �� � � ��

, is at mostpolynomial in the problem size.

EA-Hard Class: For the given EA, starting from someinitial population

� � , the mean number of generationsneeded by the EA to solve the problem, i.e.,

� �� � � ��

, isat least exponential in the problem size.

– p.29

Page 30: How Powerful Is Your Evolutionary Algorithm

EA-Easy Problems

More details are in (He and Yao, 2004) a

Given an EA, a problem is EA-easy if and only if there existsa distance function

� ��� �

such that

� ��� �� ��

��

, where ��

��

is polynomial in the problemsize �, and

the one-step mean drift satisfies: for any population

��

which is not an optimal solution,

� � � � ��

� � � � ��� � � � ��

where � � �

is a constant.aJ. He and X. Yao. A Study of Drift Analysis for Estimating Computation Time

of Evolutionary Algorithms. Natural Computing, 3(1), pp.21-35, 2004.

– p.30

Page 31: How Powerful Is Your Evolutionary Algorithm

EA-Hard Problems

More details are in (He and Yao, 2004) a

Given an EA, a problem is GA-hard if and only if there existsa distance function

� ��� �

such that

for some population � � � ��� � ��

��

, where ��

��

isexponential in the problem size �, and

the one-step mean drift satisfies: for any population

��

which is not an optimal solution,

� � � � ��

� � � � �� � � � � ��

� � ��

where � is a positive constant.aJ. He and X. Yao. A Study of Drift Analysis for Estimating Computation Time

of Evolutionary Algorithms.Natural Computing, 3(1), pp.21-35, 2004.

– p.31

Page 32: How Powerful Is Your Evolutionary Algorithm

Discussions on Analytical Tools

Advantages of Drift Analysis:

Intuitive and simple idea: time= distance/drift;

Unified framework: it can be used to analyse thecomputation time, convergence, etc., of EAs;

Mathematical foundation: it can be thought as anapplication of martingale theory. We can get the helpfrom real theoreticans.

Disadvantages of Drift Analysis:

It is nontrivial to define a distance function;

It is hard to estimate the mean drift.

– p.32

Page 33: How Powerful Is Your Evolutionary Algorithm

What Make a Problem EA-Hard

There are two and only two classes of EA-hardcombinatorial problems;

The “wide-gap” problem. There is at least one wide plateau(gap) in the search space that the EA finds it hard toescape from.

The “long-path” problem. There are exponential number ofplateaus in the search space.

– p.33

Page 34: How Powerful Is Your Evolutionary Algorithm

Conclusions

Drift analysis can be used to analyse the convergenceand computation time of EAs.

Population can be beneficial to EAs, but not always.

Necessary and sufficient conditions for EA-hardnesscan be established using drift analysis.

Where the EA-hardness is: “wide-gap” and “long-path”problems.

– p.34

Page 35: How Powerful Is Your Evolutionary Algorithm

References (I)

Downloadable papers:www.cs.bham.ac.uk/ �xin/journal papers.html

1. J. He and X. Yao, “Time Complexity Analysis of anEvolutionary Algorithm for Finding Nearly MaximumCardinality Matching,” Journal of Computer Scienceand Technology, 19(4):450-458, July 2004.

2. J. He and X. Yao, “A study of drift analysis forestimating computation time of evolutionaryalgorithms,” Natural Computing, 3(1):21-35, January2004.

3. J. He and X. Yao, “Towards an Analytic Framework forAnalysing the Computation Time of EvolutionaryAlgorithms,” Artificial Intelligence, 145(1-2):59-97, April2003.

– p.35

Page 36: How Powerful Is Your Evolutionary Algorithm

References (II)

Downloadable papers:www.cs.bham.ac.uk/ �xin/journal papers.html

4. J. He and X. Yao, “From an Individual to a Population:An Analysis of the First Hitting Time ofPopulation-Based Evolutionary Algorithms,” IEEETransactions on Evolutionary Computation,6(5):495-511, October 2002. (According to EssentialScience Indicators

� �

, the number of citations thispaper had received by the end of 2004 placed it in thetop

within its field.)

5. J. He and X. Yao, “Drift Analysis and Average TimeComplexity of Evolutionary Algorithms,” ArtificialIntelligence, 127(1):57-85, March 2001. Erratum in140(1):245-248, September 2002.

– p.36