# How to move a magnet to a specific coordinate on a board

I was just reading about Claude Shannon's famous maze-solving mouse, Theseus, which used a movable magnet under the maze to draw the mouse in a given direction. I'd like to play around with this idea.

I'm trying to decide the cheapest and simplest way to have a square board of, say, 40cm by 40cm, and programatically move a magnet on that board to a given coordinate with reasonable precision.

My first thought was to position a series of electromagnets at the edge of the board that, when activated in various combinations, could exert the correct force on the movable magnet.

This seems like a fairly crude solution that would be difficult to control with accuracy. I also thought of placing a matrix of electromagnets under the board and activating them in a timed sequence, but this seems like an unnecessarily complex solution requiring far more parts and pins than necessary.

I remember enough EM that I think I could work out the necessary field equations to get the magnet where it needs to go, but am unsure how to best create that field.