Question: Implement Randomized Hill Climbing and apply it to a minimization problem involving the following function f: f(xx) = [1 + (x + y +1)-(19 -

 Implement Randomized Hill Climbing and apply it to a minimization probleminvolving the following function f: f(xx) = [1 + (x + y

Implement Randomized Hill Climbing and apply it to a minimization problem involving the following function f: f(xx) = [1 + (x + y +1)-(19 - 14x + 3x2 -14y + xy +3y2)][30 + (2x - 3y)-(18-32x + 12x2 + 4y - 36xy + 27y2)], where -2 sxy s2 Your procedure should be called RHC and have the following input parameters: sp: is the starting point of the Randomized Hill Climbing run p the number of neighbors of the current solution that will be generated z neighborhood size; for example if z is set to z=0.5 p neighbors for the current solution s are generated by adding vectors v=(z1,z2) with z1 and z2 being random numbers in (-0.5,+0.5] uniformly distributed seed which is an integer that will be used as the seed for the random generator you employ in your implementation. . RHC returns a vector (x.x) the value of f(xx) and the number solutions that were generated during the run of RHC. Run your randomized hill climbing procedure RHC twice for the following parameters: sp = (0.4, -0.5), (-0.5, 0.3), (1, -2) and (0,0) p = 30 and 120 z = 0.03 and 0.1 For each of the 32 runs report: a. the best solution (x,x) found and its value forf b. number of solutions generated during the runs. Summarize your results in 4 tables; one for each pand z combination. Interpret?the obtained results evaluating solution quality, algorithm speed, impact of sp, p, and z on solution quality and algorithm speed. Do you believe with other values for p and r better results could be accomplished? At last, assess if RHC did a good, medium or bad job in computing a (local) minimum for f. 2 3 4 A vector (x,y) with x.y in [-2, 2] If you run RHC with the same values for sp, p, z and seed it will always return the same solution; if you run is with the same values for sp, p, z and a different seed, it likely will return a different solution and the number of solutions searched is almost always different. Make sure you use a different seed for your random generator to get a different sequence of random numbers for the 2 runs! Count the number of times function f is called during the search! (30, 0.03), (120,0.1), (30,0.1), (120, 0.03) At least 25% of the available points will be allocated to interpreting the results. 6 7 Submission Guidelines: Run1 Run2 misol f(sol) sol searched p=30& z=0.03 f(sol) #sol sol searched _(0.4,-0.5) (-0.5, 0.3) _{1,-2) (0,0) each of the 4 You should summarize your results in 4 tables formatted as the above, combination of p & z. Implement Randomized Hill Climbing and apply it to a minimization problem involving the following function f: f(xx) = [1 + (x + y +1)-(19 - 14x + 3x2 -14y + xy +3y2)][30 + (2x - 3y)-(18-32x + 12x2 + 4y - 36xy + 27y2)], where -2 sxy s2 Your procedure should be called RHC and have the following input parameters: sp: is the starting point of the Randomized Hill Climbing run p the number of neighbors of the current solution that will be generated z neighborhood size; for example if z is set to z=0.5 p neighbors for the current solution s are generated by adding vectors v=(z1,z2) with z1 and z2 being random numbers in (-0.5,+0.5] uniformly distributed seed which is an integer that will be used as the seed for the random generator you employ in your implementation. . RHC returns a vector (x.x) the value of f(xx) and the number solutions that were generated during the run of RHC. Run your randomized hill climbing procedure RHC twice for the following parameters: sp = (0.4, -0.5), (-0.5, 0.3), (1, -2) and (0,0) p = 30 and 120 z = 0.03 and 0.1 For each of the 32 runs report: a. the best solution (x,x) found and its value forf b. number of solutions generated during the runs. Summarize your results in 4 tables; one for each pand z combination. Interpret?the obtained results evaluating solution quality, algorithm speed, impact of sp, p, and z on solution quality and algorithm speed. Do you believe with other values for p and r better results could be accomplished? At last, assess if RHC did a good, medium or bad job in computing a (local) minimum for f. 2 3 4 A vector (x,y) with x.y in [-2, 2] If you run RHC with the same values for sp, p, z and seed it will always return the same solution; if you run is with the same values for sp, p, z and a different seed, it likely will return a different solution and the number of solutions searched is almost always different. Make sure you use a different seed for your random generator to get a different sequence of random numbers for the 2 runs! Count the number of times function f is called during the search! (30, 0.03), (120,0.1), (30,0.1), (120, 0.03) At least 25% of the available points will be allocated to interpreting the results. 6 7 Submission Guidelines: Run1 Run2 misol f(sol) sol searched p=30& z=0.03 f(sol) #sol sol searched _(0.4,-0.5) (-0.5, 0.3) _{1,-2) (0,0) each of the 4 You should summarize your results in 4 tables formatted as the above, combination of p & z

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!