Note to 4th year students - PowerPoint PPT Presentation

1 / 17
About This Presentation
Title:

Note to 4th year students

Description:

students interested in doing masters degree and those who intend to apply for ... place n chess queens, n 3, on an n x n chess board so no queen threatens another ... – PowerPoint PPT presentation

Number of Views:42
Avg rating:3.0/5.0
Slides: 18
Provided by: laurentian3
Category:
Tags: 4th | note | students | year

less

Transcript and Presenter's Notes

Title: Note to 4th year students


1
Note to 4th year students
  • students interested in doing masters degree and
    those who intend to apply for OGS/NSERC
    scholarships should complete the required forms
    and apply before October 19. The forms can be
    obtained through the research office website.

2
Optimization Problems
  • searching a space when paths dont matter

3
Local search algorithms
  • If paths dont matter, algorithms are able to
    jump from state to state (ie not follow edges)
  • Example
  • the n queens problem
  • place n chess queens, ngt3, on an n x n chess
    board so no queen threatens another according to
    chess rules

4
Optimisation problems
  • find maximum value of a function over a parameter
    state space
  • e.g., one-dimensional max f(x) over x

f(x)
x
5
Optimisation problems
  • e.g., 2-dimensional max f(x,y) over x,y

y
f(x,y)
x
6
Algorithms
  • hill-climbing (greedy best-first dfs)
  • weaknesses
  • local optima
  • ridges
  • plateaux
  • variations on hill-climbing to avoid the traps

7
Hill climbing
8
Getting outside the local area
  • variations on hill-climbing
  • choosing a successor that may not be the optimal
    (escape by path)
  • random restart (escape by jump)
  • simulated annealing

9
Getting outside the local area
  • choosing a successor that may not be the optimal
    (escape by path)

10
Getting outside the local area
  • random restart

11
Getting outside the local area
  • simulated annealing
  • random move is generated, probability of moving
    is based on change in value

f(x)
x
12
Simulated annealing
  • Probability of move function
  • Probability of making bad move decreases with time

probability of moving

-
13
Avoiding paths altogether
  • genetic algorithms
  • pick set of states randomly
  • order states by fitness
  • create new set of states by combining state
    variables of most fit
  • make a few random changes to state variables
  • go to 2

14
Genetic algorithm example
  • Guessing a 32 bit sequence
  • fitness function number of matching bits
  • (hill-climbing would be better!)

15
Genetic algorithm example
  • population size 4
  • first generation random fitness
  • 0110 1010 1011 0110 0110 1010 1010 1110 14
  • 1100 1101 0110 0101 1101 0010 0000 1010 15
  • 1101 0110 1011 1010 1001 1010 1010 1110 19
  • 0010 1101 1000 0111 0010 0110 1001 1001 13
  • order 3,2,1,4
  • cross 3 x 2 and 3 x 1 for next generation

16
Genetic algorithm example
  • crossing 3 x 2
  • pick random cut point after 9th
  • 1100 1101 0110 0101 1101 0010 0000 1010
  • 1101 0110 1011 1010 1001 1010 1010 1110
  • recombine crossed pieces
  • 1100 1101 0011 1010 1001 1010 1010 1110 21
  • 1101 0110 1110 0101 1101 0010 0000 1010 13
  • crossing 3 x 1 (cut after 21)
  • 1101 0110 1011 1010 1001 1010 1010 1110 18
  • 0110 1010 1011 0110 0110 1010 1010 1110 15
  • (4 potential new sequences)

17
Genetic algorithm example
  • next generation
  • 1100 1101 0110 0101 1101 0010 0000 1010 15
  • 1101 0110 1011 1010 1001 1010 1010 1110 19
  • 1100 1101 0011 1010 1001 1010 1010 1110 21
  • 1101 0110 1011 1010 1001 1010 1010 1110 18
  • (2 best new combinations replace 2 worst from
    original population)
  • repeat
Write a Comment
User Comments (0)
About PowerShow.com