This preview has intentionally blurred sections. Sign up to view the full version.View Full Document
Unformatted text preview: HW 5 Solutions 2010 Points possible: 20 1. A 5-bit binary GA with a population size of 4 is used to solve a maximization problem. At generation zero the following information is available to you: Member String Fitness 1 10001 20 2 11001 10 3 00101 5 4 01101 15 The following GA algorithm parameters hold: Probability of crossover = 1 In each crossover operation a one-point crossover strategy with 2 parents will be employed to produce exactly one child. The first part of the genes of the child (bits 1 to the crossover point) will come from the first parent, and the second part (from the crossover point to the end of the string) from the second parent. If roulette wheel selection is employed and if there is no mutation, (a) (2 points) What is the chance that a member in generation 1 will be of the form 1xxxx? What is the chance that a member in generation 1 will be of the form 0xxxx? Total fitness of all parents = 20+10+5+15 = 50 Let X denote the event that a parent with form 1xxx is chosen as the first parent. P[X] = P[choose member 1 or 2] = P[choose 1] + P[choose 2] = 20/50+10/50 = 3/5 Let Y denote the event that a parent with form 0xxx is chosen as the first parent. P[Y] = P[choose member 3 or 4] = P[choose 3]+P[Choose 4] = 5/50+15/50 = 2/5 Note that P[Y] = 1 – P[X] Students should not perform combinations because each member does not have an equal probability of being chosen. Now assume bit-wise mutation probability, pMutation = 0.01 (b) . (2 points) What is the chance now that a member in generation 1 will be of the form 1xxxx? Two things can happen now. Either (1) member 1 or member 2 is chosen and there is no mutation on the first bit, or (2) member 3 or member 4 is chosen and there is mutation on the first bit. HW 5 Solutions 2010 P[X] = P[(choose member 1 or 2) and (no mutation on the first bit)] + P[(choose member 3 or 4) and (mutation on the first bit)] =3/5*(1-0.01) + 2/5(0.01) = 0.598 What is the chance that a member in generation 1 will be of the form 0xxxx? A similar operation can be applied for this question. One can also obtain the answer by noting that a member in generation 1 will be of the form 0xxx is the same as saying that a member in generation 1 will not be of the form 1xxx: P[Y] = 1 – P[X] = 0.402 2. Real-valued optimization – Bump function . You will code a real-value GA and apply it to maximize the function outlined below. Your real-value GA will look very similar to your binary GA coding (i.e. assuming your binary GA works OK, modify your binary GA so that it works as a real-value GA)....
View Full Document
This note was uploaded on 10/02/2011 for the course ORIE 5430 taught by Professor Shoemaker during the Fall '11 term at Cornell.
- Fall '11