Skip to content

hamdilyes/randomwalks

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 

Repository files navigation

Random Walks in $\mathbb{Z}^2$ : Anthill probability puzzle

Can you solve this puzzle?

An ant leaves its anthill in order to forage for food. It moves with the speed of $1$ per second, but it doesn't know where to go, therefore every second it moves randomly $1$ directly north, south, east or west with equal probability.

  1. If the food is located on east-west lines $2$ to the north and $2$ to the south, as well as on north-south lines $2$ to the east and $2$ to the west from the anthill, how long will it take the ant to reach it on average?

  2. What is the average time the ant will reach food if it is located only on a diagonal line passing through $(1, 0)$ and $(0, 1)$ points?

  3. Can you write a program that comes up with an estimate of average time to find food for any closed boundary around the anthill? What would be the answer if food is located outside an area defined by $\left(\dfrac{x – 0.25}{3}\right)^2 + \left(\dfrac{y – 0.25}{4}\right)^2 < 1$ in coordinate system where the anthill is located at $(x = 0, y = 0)? Provide us with a solution rounded to the nearest integer.

Source: Optiver

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages