Saturday, January 11, 2014

One Blind Mouse - An application of the Distance Formula

   In the previous post (The Distance Formula in Scratch, January 2014) I presented a tutorial on programming the distance formula from analytic geometry in Scratch.
   This Scratch project, One Blind Mouse, uses the distance formula to model how a blind mouse using its sense of smell can find a piece of cheese. The closer the mouse is to the cheeses, the stronger the smell and the farther away the mouse is from the cheese, the weaker the smell. Watch this very short video of the project.
   In the project, the algorithm causes the blind mouse to move over the plane, turning towards the cheese so as to continually shorten the distance between it and the cheese. When the red tip of the mouse's cane touches the cheese, the mouse has found it. Note that the mouse always spirals into the cheese even though 'spiral' is not in the code!
   You can view and download the project by clicking on this link.

No comments:

Post a Comment