Question
Please include your work. 1) a) This is a variant of the Josephus problem. Josephus was one of the leaders of Jewish revolt against Rome
Please include your work.
1) a) This is a variant of the Josephus problem. Josephus was one of the leaders of Jewish revolt against Rome in the year 66. Assume that n prisoners were sitting in a circle and numbered clockwise from 1,2, ...n. Proceeding clockwise, every other prisoner was killed. Prisoner 2 was killed first, then prisoner 4, and this continued until there was only one prisoner left. This lone remaining prisoner was not killed and considered the lone survivor. The goal was to stand in the correct position initially such that you would be the lone survivor. Denote the position of the lone survivor as J(n) where n is the number of people siting in the circle. As an example: J(5) = 3 (Order of deaths: 2,4,1,5). Prove using induction that J(2^i) = 1 for all i >= 1.
b) Give a recursive definition of the function min so that min(a1,a2,....an) is the minimum of the n numbers a1,a2,....an.
c) Find f(n) when n = 5^k, where f satisfies the recurrence relation f(n) = 4f(n/5) + n^2, with f(1) = 1.
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