Prev: M9 Next: M11
Back to week 6 page: Link

# M10 Written (Math) Problems

📗 Enter your ID (the wisc email ID without @wisc.edu) here: and click (or hit enter key)
📗 The official deadline is August 1, but you can submit or resubmit without penalty until August 10.
📗 The same ID should generate the same set of questions. Your answers are not saved when you close the browser. You could print the page: , solve the problems, then enter all your answers at the end.
📗 Please do not refresh the page: your answers will not be saved.
📗 Please report any bugs on Piazza.

# Warning: please enter your ID before you start!


# Question 1



# Question 2



# Question 3



# Question 4



# Question 5



# Question 6



# Question 7



# Question 8



# Question 9



# Question 10



📗 [3 points] If \(h_{1}\) and \(h_{2}\) are both admissible heuristic functions, which ones of following are also admissible heuristic functions?
Hint See Fall 2019 Midterm Q4 Q7 Q8 Q9, Fall 2018 Midterm Q5, Spring 2018 Midterm Q2, Fall 2006 Final Q3, Fall 2006 Midterm Q7, Fall 2005 Final Q3, Fall 2005 Midterm Q2. Since \(h_{1}\) and \(h_{2}\) are admissible, for any \(n\), \(0 \leq h_{1}\left(n\right) \leq h^\star\left(n\right)\) and \(0 \leq h_{2}\left(n\right) \leq h^\star\left(n\right)\). It means if \(0 \leq h_{3}\left(n\right) \leq h_{1}\left(n\right)\) or \(0 \leq h_{3}\left(n\right) \leq h_{2}\left(n\right)\), then it must be true that \(0 \leq h_{3}\left(n\right) \leq h^\star\left(n\right)\), i.e. \(h_{3}\) is also admissible.
📗 Choices:





None of the above
📗 [3 points] Let \(h_{1}\) be an admissible heuristic from a state to the optimal goal, A* search with which ones of the following \(h\) will be admissible?
Hint See Fall 2019 Midterm Q1, Fall 2018 Midterm Q6, Fall 2017 Midterm Q10. Since \(h_{1}\) is admissible, for any \(n\), \(0 \leq h_{1}\left(n\right) \leq h^\star\left(n\right)\). It means if \(0 \leq h\left(n\right) \leq h_{1}\left(n\right)\), then it must be true that \(0 \leq h\left(n\right) \leq h^\star\left(n\right)\), i.e. \(h\) is always admissible. Since \(h^\star\) can be arbitrarily large, only when \(h\left(n\right) < 0\) for some \(n\) or when \(h\left(0\right) \neq 0\), \(h\) is never admissible.
📗 Choices:





None of the above
📗 [3 points] Let \(h_{1}\) be an admissible heuristic from a state to the optimal goal, A* search with which ones of the following \(h\) will be admissible?
Hint See Fall 2019 Midterm Q1, Fall 2018 Midterm Q6, Fall 2017 Midterm Q10. Since \(h_{1}\) is admissible, for any \(n\), \(0 \leq h_{1}\left(n\right) \leq h^\star\left(n\right)\). It means if \(0 \leq h\left(n\right) \leq h_{1}\left(n\right)\), then it must be true that \(0 \leq h\left(n\right) \leq h^\star\left(n\right)\), i.e. \(h\) is always admissible. Since \(h^\star\) can be arbitrarily large, only when \(h\left(n\right) < 0\) for some \(n\) or when \(h\left(0\right) \neq 0\), \(h\) is never admissible.
📗 Choices:





None of the above
📗 [2 points] Let the states be 2D integer points with integer coordinates \(\left(i, j\right)\) with boundary constrains and . Each state \(\left(i, j\right)\) has four successors \(\left(i - 1, j\right), \left(i + 1, j\right), \left(i, j - 1\right), \left(i, j + 1\right)\) or a subset thereof subject to the boundary constraints. The score of state \(\left(i, j\right)\) is . Which local minimum will be reached if hill climbing is used starting from ?
Hint See Fall 2017 Midterm Q9. Due to the convexity of the function, hill climbing will eventually reach the global minimum. If the coefficient in front of \(i\) (or \(j\)) is positive, then \(i\) (or \(j\)) should be as small as possible at the global minimum. If the coefficient in front of \(i\) (or \(j\)) is negative, then \(i\) (or \(j\)) should be as large as possible at the global minimum.
📗 Answer (comma separated vector): .
📗 [2 points] In simulated annealing one accepts a transition from \(s\) to an inferior neighbor \(t\) with probability \(\exp\left(\dfrac{- \left| f\left(s\right) - f\left(t\right) \right|}{T}\right)\), where \(T\) is the temperature parameter. Suppose \(f\left(s\right)\) = and \(f\left(t\right)\) = . At what temperature is the transition probability ?
Hint See Fall 2018 Midterm Q10. Solve \(\exp\left(\dfrac{- \left| f\left(s\right) - f\left(t\right) \right|}{T}\right) = p\) for \(T\).
📗 Answer: .
📗 [2 points] In simulated annealing we move from \(s\) to an inferior neighbor \(t\) with probability \(\exp\left(\dfrac{- \left| f\left(s\right) - f\left(t\right) \right|}{T}\right)\), where \(T\) is the temperature parameter. Suppose \(f\left(s\right)\) = and \(f\left(t\right)\) = and \(T\) = . What is the probability we stay at \(s\) instead of moving to \(t\)?
📗 Note: we are minimizing the score.
Hint See Fall 2017 Midterm Q11. If \(f\left(s\right) > f\left(t\right)\), the probability of leaving is 1. If \(f\left(s\right) \leq f\left(t\right)\), the probability of leaving is \(\exp\left(\dfrac{- \left| f\left(s\right) - f\left(t\right) \right|}{T}\right)\). The probability of staying is 1 minus the probability of leaving.
📗 Answer: .
📗 [2 points] Consider the following version of hill climbing: at initial state \(s\) we randomly choose one of \(s\)'s neighbors with equal probability. If the chosen neighbor has a strictly better score than \(s\) we move to the neighbor; otherwise we stay at \(s\). Assume \(s\) has neighbors, and only of the neighbors has a strictly better score than \(s\). What is the chance that we move out of \(s\) in iterations or less?
Hint See Fall 2016 Midterm Q6. The probability of moving out is 1 minus the probability of staying (seeing a worse neighbor) in all \(T\) iterations.
📗 Answer: .
📗 [3 points] Four individuals (i.e. candidate solutions) in the current generation are given by -digit ( dimensional) sequences: . Individual 1: ; Individual 2: ; Individual 3: ; Individual 4: . The fitness function is . What is the result of performing 1-point crossover for the sequences with the highest fitness (break ties by preferring the sequence that appears earlier in the list) with a cross-point between digit and digit .
📗 Note: the first line representing the first child should start with the sequence with the highest fitness, and the second line representing the second child should start with the sequence with the second highest fitness.
Hint See Spring 2017 Midterm Q2. Compute the fitness of all four sequences and find the two with the highest fitness say \(d^{\left(1\right)}, d^{\left(2\right)}\). The crossover of the two sequences between digits \(i\) and \(i + 1\) are \(d^{\left(1\right)}_{1}, ..., d^{\left(1\right)}_{i}, d^{\left(2\right)}_{i+1}, ..., d^{\left(2\right)}_{6}\) and \(d^{\left(2\right)}_{1}, ..., d^{\left(2\right)}_{i}, d^{\left(1\right)}_{i+1}, ..., d^{\left(1\right)}_{6}\).
📗 Calculator: .
📗 Answer (matrix with 2 lines, each line is a comma separated vector):
📗 [3 points] Consider a state space where the states are positive integers between 1 and . State \(i\) has two neighbors \(i - 1\) and \(i + 1\) (subject to the boundary constraints). State \(i\) has score . If one runs the hill climbing algorithm, which initial states can reach the global minimum? Break ties by moving towards the global minimum. If there are multiple global minima, list the states that lead to all of them.
Hint See Spring 2019 Midterm Q10, Fall 2017 Midterm Q8, Fall 2009 Midterm Q5. Try to solve the problem with a small \(n\) and find the pattern. Alternatively, start with the global minimum \(i^\star\), keep count the states while \(s\left(i - 1\right) \geq s\left(i\right), i < i^\star\) or \(s\left(i + 1\right) \geq s\left(i\right), i > i^\star\).
📗 Answer (comma separated vector): .
📗 [1 points] Please enter any comments and suggestions including possible mistakes and bugs with the questions and the auto-grading, and materials relevant to solving the questions that you think are not covered well during the lectures. If you have no comments, please enter "None": do not leave it blank.
📗 Answer: .

# Grade


 ***** ***** ***** ***** ***** 

 ***** ***** ***** ***** *****

# Submission


📗 Please do not modify the content in the above text field: use the "Grade" button to update.


📗 Please wait for the message "Successful submission." to appear after the "Submit" button. If there is an error message or no message appears after 10 seconds, please save the text in the above text box to a file using the button or copy and paste it into a file yourself and submit it to Canvas Assignment M10. You could submit multiple times (but please do not submit too often): only the latest submission will be counted.
📗 You could load your answers from the text (or txt file) in the text box below using the button . The first two lines should be "##m: 10" and "##id: your id", and the format of the remaining lines should be "##1: your answer to question 1" newline "##2: your answer to question 2", etc. Please make sure that your answers are loaded correctly before submitting them.



# Solutions

📗 Some of the past exams referenced in the Hints can be found on Professor Zhu's and Professor Dyer's websites: Link and Link.
📗 Some of the questions are from last year, and I recorded videos going through them, the links are at the bottom of the Week 1 to Week 8 pages, for example: W4 and W8.
📗 The links to the solutions the students volunteered to share on Piazza will be collected in this post around the official deadline: Link.





Last Updated: April 29, 2024 at 1:11 AM