COMPARISON BETWEEN A SIMPLE GA AND AN ANT SYSTEM FOR THE CALIBRATION OF A RAINFALL-RUNOFF MODEL NELSON OBREGÓN RAFAEL E. OLARTE 6th International Conference on Hydroinformatics Singapore, June 2004
OBJECTIVES 1.To propose an Ant System for solving continuous functions. 2.To compare this AS with a simple GA in terms of their Parsimony, Efficacy and Efficiency (only the calibration problem of the Thomas Model will be considered).
CONTENTS 1.Brief explanation of a simple AS 2.Adapting an AS for the Thomas Model calibration problem 3.Adapting a GA for the Thomas Model calibration problem 4.Comparison between the 2 algorithms 5.Conclusions
1.BRIEF EXPLANATION OF A SIMPLE AS
The Traveler Salesman Problem ??
A Simple Ant System 1) Distribute randomly m ants on m of the n cities.
A Simple Ant System 1) Distribute randomly m ants on m of the n cities. 2) Every ant makes a random tour and dies.
A Simple Ant System 1) Distribute randomly m ants on m of the n cities. 2) Every ant makes a random tour and dies. 3) Update pheromone trails ij on the segments (ij). 3) Update pheromone trails ij upon segments ( ij ).
A Simple Ant System 1) Distribute randomly m ants on m of the n cities. 2) Every ant makes a random tour and then dies. 3) Update pheromone trails ij upo segments (ij). 4) Distribute randomly m ants on m of the n cities.
A Simple Ant System 1) Distribute randomly m ants on m of the n cities. 2) Every ant makes a random tour and then dies. 3) Update pheromone trails ij upo segments (ij). 4) Distribute randomly m ants on m of the n cities. 5) Every ant makes a complete tour according to probability p ij and then dies. ? ? ? ? ? ? ? 5) Every ant makes a complete tour according to probability p ij and the dies.
A Simple Ant System 1) Distribute randomly m ants on m of the n cities. 2) Every ant makes a random tour and then dies. 3) Update pheromone trails ij upon segments (ij). 4) DistribUte randomly m ants on m of the n cities. 6) Update pheromone trails ij upon segments (ij). 5) Every ant makes a complete tour according to probability p ij and then dies. 6) Update pheromone trails ij upon segments (ij).
A Simple Ant System 1) Distribute randomly m ants on m of the n cities. 2) Every ant makes a random tour and then dies. 3) Update pheromone trails ij upon segments (ij). 4) Distribute randomly m ants on m of the n cities. 6) Update pheromone trails ij upon segments (ij). 5) Every ant makes a complete tour according to probability p ij and then dies. 7) Has the # of iterations ( maxIter) been completed? 7) Has the # of iterations ( maxIter ) been reached?
2.ADAPTING AN AS FOR THE THOMAS MODEL CALIBRATION PROBLEM
The Thomas Model Calibration Problem P ET Q? CATCHMENT PRECIPITATION EVAPOTRANSPIRATION STREAMFLOW Sw 0, Sg 0 a, b, c, d Parameters Initial Conditions Sw 0, Sg 0 a, b, c, d Initial Conditions Parameters
The Thomas Model Calibration Problem Sw 0, Sg 0 a, b, c, d Initial Conditions Parameters a b c d Sw 0 Sg 0
The Thomas Model Calibration Problem a b c d Sw 0 Sg 0 a b c d Sw 0 Sg 0 b Adapting the simple AS
b a b c d Sw 0 Sg 0 1) Distribute randomly m ants on m of the n cities. 2) Every ant makes a random tour and then dies. 3) Update pheromone trails ij upon segments (ij). 4) Distribute randomly m ants on m of the n cities. 6) Update pheromone trails ij upon segments (ij). 5) Every ant makes a complete tour according to probability p ij and then dies. 7) Has the # of iterations ( maxIter) been completed? Adapting the simple AS
b a c Sw 0 Sg 0 d b 1) Distribute randomly m ants on m of the n cities. 2) Every ant makes a random tour and then dies. 3) Update pheromone trails ij upon segments (ij). 4) Distribute randomly m ants on m of the n cities. 6) Update pheromone trails ij upon segments (ij). 5) Every ant makes a complete tour according to probability p ij and then dies. 7) Has the # of iterations ( maxIter) been completed? Adapting the simple AS Adapting the MAX-MIN AS At each iteration, set limits for the values of ij, that is, min and max. At each iteration, only update ij of the iteration best found solution. Every globUpdate iterations, update the ij of the global best found. 1) Distribute randomly m ants on m of the n cities. 2) Let each ant make a random tour and die. 6) Distribute randomly m ants on m of the n cities. 4) Update pheromone trails ij upon segments (ij) within max and min. 7) Let each ant make a complete tour (according to probability p ij ) and die. Update the limit max. 8) Has the # of iterations ( maxIter) been completed? 3) Calculate max and set all segments with that pheromone. 5) If an interval of globUpdate iterations has been made, reinforce pheromone trail of the global best found solution. Parameters’ Sensibility + – adcbadcb
3.ADAPTING A GA FOR THE THOMAS MODEL CALIBRATION PROBLEM
A Simple GA (6) Number of generations maxGen reached? 1) Generate population of popSize chromosomes. 2) Evaluate the objective function in each chromosome. 3) Select the fittest chromosomes using normalization. 4) Generate next population using double point crossover (with p c probability) and mutation (with p m probability). 5) Get rid of the e worst chromosomes and replace them with the e best from the previous population..
Chromosomes a b c d Sw 0 Sg 0
Elitism Generation t-1Generation t e best e worst
Other Algorithm’s Properties Double-Point Crossover Double-Point Crossover Roulette-Wheel selection with previous normalization according to the following equation. Roulette-Wheel selection with previous normalization according to the following equation.
4.COMPARISON BETWEEN THE 2 ALGORITHMS
Area of Study used for the Comparison CATCHMENTAREA [km 2 ]Q i -min [mm/month] Q i -max [mm/month] Curibital56, Susagua31, Bogotá (Partial)85, Localization: near Bogotá, Colombia.
Search Spaces kk adcbSw 0 Sg 0 Lower Bound Upper Bound Precision bkbk MAX-MIN Ant System # of genes Simple Genetic Algorithm 201 x 1000 x 900 x 341 x 501 x 501 = 3.6x ( ) = 3.6x10 6
Efficacy Parameters used MM AS m = 150 globUpdate = 10 = 0.95 min = 0.1 GA popSize = 75 elite = 1 p m = 0.1 p c = 0.6 Parameters used MM AS m = 150 globUpdate = 10 = 0.95 min = 0.1 GA popSize = 75 elite = 1 p m = 0.1 p c = 0.7 Parameters used MM AS m = 150 globUpdate = 10 = 0.95 min = 0.1 GA popSize = 75 elite = 1 p m = 0.01 p c = 0.6
Efficiency Parameters used MM AS m = 50 globUpdate = 10 = 0.95 min = 0.1 GA popSize = 50 elite = 1 p m = 0.1 p c = 0.6
Parsimony 1) Distribute randomly m ants on m of the n cities. 2) Let each ant make a random tour and die. 6) Distribute randomly m ants on m of the n cities. 4) Update pheromone trails ij upon segments (ij) within max and min. 7) Let each ant make a complete tour (according to probability p ij ) and die. Update the limit max. 8) Has the # of iterations ( maxIter) been completed? 3) Calculate max and set all segments with that pheromone. 5) If an interval of globUpdate iterations has been made, reinforce pheromone trail of the global best found solution. (6) Number of generations maxGen reached? 1) Generate population of popSize chromosomes. 2) Evaluate the objective function in each chromosome. 3) Select the fittest chromosomes using normalization. 4) Generate next population using double point crossover (with p c probability) and mutation (with p m probability). 5) Get rid of the e worst chromosomes and replace them with the e best from the previous population.. Simple GA MAX-MIN AS maxGenmaxIter popSizem eliteglobUpdate pmpm pcpc min
Parsimony Exploitation Exploration p m globUpdate min elite
maxGen maxIter popSize m
elite globUpdate Other Parameters: maxGen=750 popSize=75 pm=0.2 pc =0.6 Other Parameters: maxIter= 300 m = 50 r = 0.97 tmin = 0.1
pcpc pmpm min maxIter= 300 m = 50 globUpdate = 10 tmin = 0.1 maxIter= 300 m = 50 globUpdate = 10 r = 0.95 :maxIter= 300 m = 50 globUpdate = 10 tmin = 0.1 maxGen = 750 popSize= 75 elite = 1 pc = 0.6
5.CONCLUSIONS
1.Some parameter values can now been taken from the present work for the application of both algorithms to the Thomas Model Calibration Problem 2.The GA showed a much better efficiency than the AS. 3.Research must continue in order to improve the implementation of AS for solving continuous functions.
THANK-YOU