120 likes | 290 Views
A Simple Genetic Algorithm for Function Optimization. Motivation. Genetic algorithm(GA) is a soft computing technique It is said that GA is fast GA can escape from local optimum
E N D
Motivation • Genetic algorithm(GA) is a soft computing technique • It is said that • GA is fast • GA can escape from local optimum • In our research, we mainly deal with hard computing (e.g. Branch and bound), we want to see the power of soft computing.
GA Flowchart START Initialization Selection Crossover Mutation No STOP? Yes END
Implementation • Encode • Decode
Implementation • Initialization • Use same encoding length for each variable • Randomly generate a population matrix (rand) • Round to nearest integer (round)
Implementation • Selection • Use objective value to measure fitness • Normalize fitness and use roulette wheel selection technique to select population for next generation • Keep the best individual to next generation
Implementation • Crossover • One-point Crossover Sourse: http://legacy.owensboro.kctcs.edu/gcaplan/anat2/notes/APIINotes2%20meiosis.htm
Implementation • Mutation • Bit String Mutation Sourse: http://www.ucl.ac.uk/~sjjgsca/DNAmutation.html
Settings • setting.txt
Results • Function