Você está na página 1de 18

|  


     
 |
 


     
   !" #
|   
  
þ In an optimization problem, we are attempting to
maximize or minimize some variable (such as profit, time,
etc.)
þ Stochastic optimization refers to any optimization
technique which incorporates probabilistic elements.
þ The random element may be a part of the problem
itself
þ Ex: valuation of financial derivatives
þ The random element may be a part of the solution
þ Ex: random search
þ Process is usually applied repeatedly, and the
aggregate results are studied.
 |

þ Œiven a set of cities and their pair-wise distances,
determine the shortest possible tour which visits each
city exactly once and ends at the starting city.

þ The traveling salesman has many applications,


including:
þ Logistics
þ Planning
þ Circuit design
þ In modified forms it is even used to study such broad
topics as DNA sequencing.
þ TSP is often used as a benchmark for testing
optimization methods.
 |

þ TSP is in the complexity class NP-Hard.
þ Not only is there no efficient algorithm for finding a
solution, a candidate solution cannot even be checked in
polynomial time.

þ Œiven n cities, the number of possible tours through them


is:

þ Starting with the first city, we have choices for the


second city, choices for the third city, and so on.
 |


þ Multiplying these together, we get:

þ And since our travel time does not depend on which


direction we take our tour, we divide this total by
two, yielding

þ =or 100 cities, there are:


466631077219720763408496194281333502453579841321908107342
9648194760879999661495780447073198807825914312684896041
36118791255926054584320000000000000000000000
possible tours. (156 digits!)
 |


An optimal TSP tour through Œermany·s 15 largest cities. It represents the


shortest of the 43,589,145,600 possible tours.
 |

þ TSP can be modeled as a graph, which makes it easier to
work with computationally.
þ The cities are represented by the graph·s vertices.
þ The roads, or paths, between the cities are represented
by the graph·s edges.
þ The distances between cities are represented by the
weights of the edges.
þ When modeled as a graph, a TSP tour becomes a
Hamiltonian cycle, and the optimal TSP tour becomes the
shortest Hamiltonian cycle of the graph.
þ The model should be a complete graph, with edges
connecting each vertex.
 |


A
12 14

32 28
29
C B

27 31
22 20

D E
7

A symmetric TSP with 5 cities


| |

þ Solving TSP becomes impractical very quickly as the


number of cities grows.

þ We can apply some sort of stochastic process to TSP in


order to achieve convergence to a nearly-optimal
solution in a much more reasonable amount of time.

þ The tour found may not be the exact optimal tour,


however it will be within a reasonable amount of the
exact optimal tour (definition of reasonable will vary by
method, problem, etc.)
 $  
  
þ A stochastic optimization method which has been
adapted to solve the TSP is Ant Colony Optimization.
þ Originally proposed in 1992 by Marco Dorigo to find an
optimal path in a graph, it is based on the behavior of ants
seeking a path between a food source and their colony.
þ The following basic behaviors make up the basis for the
algorithm:
þ An ant will wander randomly until a food source is found.
þ Once a food source is found, the ant will return directly to the colony,
laying down a pheromone trail as it goes.
þ If an ant encounters a pheromone trail, it is more likely to follow
that trail than to continue wandering randomly.
þ The pheromone trail will evaporate over time if not reinforced.
 $  
  
þ Based on these behaviors, the ants will converge to the
shortest path between the colony and the food source.
-If more than one path exists,
the shorter path will be
traveled by a larger number
of ants in the same amount of
time
-The pheromone trail on the
shorter path will then
become stronger than the
longer path, making it more
probable to be followed.
-Eventually the pheromone
trail on the longer path will
dissipate, and the shortest
Image by
ohann Dréo path will be taken by all ants.
     |
þ In order to devise an adaptation of ant colony
optimization to solve a TSP, we give our artificial ants a
few properties in addition to the ones already discussed:
þ An ant has a memory, and will only visit a city it has
not yet visited.
þ An ant can ´seeµ the distance of a path, and is more
likely to travel to a city which is a shorter distance
from the city it is currently in.
þ N ants are distributed randomly, and move from city to city on a
TSP graph.
þ At each time step, an artificial ant chooses a city to move to
based on a probabilistic function of both the pheromone
accumulated on an edge and the distance of that edge.
     |
þ The pheromone trails are updated both locally and
globally:
þ After each move from city to city, the trail on that edge is
updated (local updating), preventing a particularly short
path from being chosen by all of the ants.
þ Once all ants have completed their tours, the ant
which had the shortest tour adds pheromone to all
edges of its tour (global updating).
þ After each iteration the pheromone trails dissipate at
a predetermined rate.
þ This process is repeated until the artificial ants converge
to a nearly-optimal tour.
   $  
  
þ Ant colony optimization has a distinct advantage over
other stochastic methods of solving similar problems,
such as genetic algorithms and simulated annealing: when
run continuously, it can react to changes in real-time.
þ If an obstacle is placed in the current path being traveled
by the colony, the basic principles take effect: the ants go
back to taking random walks around the obstacle.
þ In the simple case, half of the ants will take the shorter
path around the obstacle, and the other half will take the
longer path.
   $  
  
     $  
  

þ Ant colony optimization has many other areas of


application:
þ
ob scheduling
þ Knapsack problem
þ Network routing
þ Data mining
þ Image processing
þ And many more«

þ The key to adapting ant colony optimization to a new problem


is in defining an appropriate heuristic which defines the
distance between two nodes in the graph to be searched by
the artificial ants.
Î 
þ M. Dorigo, L. Œambardella, Ant colonies for the traveling
salesman problem, 1996
þ E. Bonabeau, M. Dorigo, Swarm Intelligence: =rom Natural
to Artificial Systems, 1999
þ ´The Traveling Salesman Problemµ,
http://www.tsp.gatech.edu/
þ Sauer, Timothy Numerical Analysis, Addison Weseley,
2005
ü   %
þ Thank you for your time.

Você também pode gostar