Question
(a) Unlike first order methods, Newtons method is able to take advantage of curvature information. Explain how Newtons method uses such information and how its
(a) Unlike first order methods, Newtons method is able to take advantage of curvature information. Explain how Newtons method uses such information and how its method of calculating where to go next differs from that of Gradient Descent.
(b) You wish to use the Simulated Annealing approach to sort a randomly permuted list intList of the first non-negative integers {0,1,2, , 1} into ascending order. Your objective function should look at all of the integers in the list, calculating for each integer how far away it is located from its correct position, and then return the sum of such distances as its objective function score. Your goal is to find an ordering of the list with all integers in their correct positions, i.e. is sorted in ascending order, and hence with an objective score of zero. You are required to write two functions: energy() which calculates this score for the list of integers, and move() which randomly modifies a list by changing the ordering of some items. Moves are expected to be conservative in nature. Provide python code for both methods.
(c) Outline, using pseudo code, a simple genetic algorithm and also give a brief description of each of its main components.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started