We have an assignment on random walk, but I can't figure out the expected value. The situation is as follows:
- In the origin there is a hunter that shoots at a duck, but misses. The duck starts at a random position $(x_0,y_0)$ at a distance of $15$ from the hunter/origin. As it is startled from the sound, it will do a random walk of $n$ steps of size $6$ in any random direction with $\theta \in ]0,2\pi[$. After $n$ steps the hunter has reloaded his gun and will not miss. The hunter has only a range of $20$ though, so if the duck is outside of that range it escapes, if not it is eaten. Assume that the duck escapes in the $n$-th step, what would the expected distance be?
I have no problem simulating the problem, throwing away the instances that ended within the shooting range of the hunter and then take the average of distances of the remaining locations, but I can't seem to figure out the exact average distance to compare with. We are required to find $N$, the number of walks required to get a correct average up to $0.1$ accuracy.
As a reply to Ronno: It is not necessary to calculate the probability of being 0.1 accurate. We need to create a convergence plot of the average distances. I quote "Show the convergence graph on the distance of the duck. For $n=1,2,3,4$, find $N_n$ for which the simulated distance is accurate up to 0.1.". That is all that is really asked, but I can't find the expected value to compare with.
- When having $n = 1$ step and not removing any instances, I would expect the average distance to be $15$, the place the duck started, but it gives something like $15.6$. Which to me is counter-intuitive. Am I doing something wrong, or is my intuition off?
After thinking back about it, this actually does make sense. The average distance of the points on a circle is only the origin of that circle if the distance is measured from the origin itself, not from any other point.