Top Banner
1 Genetic Algorithms
19

1 Genetic Algorithms. CS 561 2 The Traditional Approach Ask an expert Adapt existing designs Trial and error.

Dec 20, 2015

Download

Documents

Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: 1 Genetic Algorithms. CS 561 2 The Traditional Approach Ask an expert Adapt existing designs Trial and error.

1

Genetic Algorithms

Page 2: 1 Genetic Algorithms. CS 561 2 The Traditional Approach Ask an expert Adapt existing designs Trial and error.

CS 561 2

The Traditional Approach

• Ask an expert• Adapt existing designs• Trial and error

Page 3: 1 Genetic Algorithms. CS 561 2 The Traditional Approach Ask an expert Adapt existing designs Trial and error.

CS 561 3

Nature’s Starting Point

Alison Everitt’s “A User’s Guide to Men”

Page 4: 1 Genetic Algorithms. CS 561 2 The Traditional Approach Ask an expert Adapt existing designs Trial and error.

CS 561 4

Optimised Man!

Page 5: 1 Genetic Algorithms. CS 561 2 The Traditional Approach Ask an expert Adapt existing designs Trial and error.

CS 561 5

Example: Pursuit and Evasion

• Using NNs and Genetic algorithm• 0 learning• 200 tries• 999 tries

Page 6: 1 Genetic Algorithms. CS 561 2 The Traditional Approach Ask an expert Adapt existing designs Trial and error.

CS 561 6

Comparisons

• Traditional• best guess

• may lead to local, not global optimum

• Nature• population of guesses

• more likely to find a better solution

Page 7: 1 Genetic Algorithms. CS 561 2 The Traditional Approach Ask an expert Adapt existing designs Trial and error.

CS 561 7

More Comparisons

• Nature• not very efficient

• at least a 20 year wait between generations• not all mating combinations possible

• Genetic algorithm• efficient and fast

• optimization complete in a matter of minutes• mating combinations governed only by “fitness”

Page 8: 1 Genetic Algorithms. CS 561 2 The Traditional Approach Ask an expert Adapt existing designs Trial and error.

CS 561 8

The Genetic Algorithm Approach

• Define limits of variable parameters• Generate a random population of designs• Assess “fitness” of designs• Mate selection• Crossover• Mutation• Reassess fitness of new population

Page 9: 1 Genetic Algorithms. CS 561 2 The Traditional Approach Ask an expert Adapt existing designs Trial and error.

CS 561 9

A “Population”

Page 10: 1 Genetic Algorithms. CS 561 2 The Traditional Approach Ask an expert Adapt existing designs Trial and error.

CS 561 10

Ranking by Fitness:

Page 11: 1 Genetic Algorithms. CS 561 2 The Traditional Approach Ask an expert Adapt existing designs Trial and error.

CS 561 11

Mate Selection: Fittest are copied and replaced less-fit

Page 12: 1 Genetic Algorithms. CS 561 2 The Traditional Approach Ask an expert Adapt existing designs Trial and error.

CS 561 12

Mate Selection Roulette:Increasing the likelihood but not guaranteeing the fittest reproduction

11%

38%

7%

16%0%

3%

25%

Page 13: 1 Genetic Algorithms. CS 561 2 The Traditional Approach Ask an expert Adapt existing designs Trial and error.

CS 561 13

Crossover:Exchanging information through some part of information (representation)

Page 14: 1 Genetic Algorithms. CS 561 2 The Traditional Approach Ask an expert Adapt existing designs Trial and error.

CS 561 14

Mutation: Random change of binary digits from 0 to 1 and vice versa (to avoid local minima)

Page 15: 1 Genetic Algorithms. CS 561 2 The Traditional Approach Ask an expert Adapt existing designs Trial and error.

CS 561 15

Best Design

Page 16: 1 Genetic Algorithms. CS 561 2 The Traditional Approach Ask an expert Adapt existing designs Trial and error.

CS 561 16

The GA Cycle

Page 17: 1 Genetic Algorithms. CS 561 2 The Traditional Approach Ask an expert Adapt existing designs Trial and error.

CS 561 17

Genetic Algorithms

Adv:

•Good to find a region of solution including the optimal solution. But slow in giving the optimal solution

Page 18: 1 Genetic Algorithms. CS 561 2 The Traditional Approach Ask an expert Adapt existing designs Trial and error.

CS 561 18

Genetic Approach

•When applied to strings of genes, the approaches are classified as genetic algorithms (GA)

•When applied to pieces of executable programs, the approaches are classified as genetic programming (GP)

•GP operates at a higher level of abstraction than GA

Page 19: 1 Genetic Algorithms. CS 561 2 The Traditional Approach Ask an expert Adapt existing designs Trial and error.

CS 561 19

Typical “Chromosome”