I found a cool maze solver.
http://www.mathworks.com/matlabcentral/fileexchange/27175-mazesolution
Usual solver is touch-always-the-right-hand-on-the-wall method, but this uses morphological operators.
I am not so sure, but the solution seems the following.
Assumption: Maze has only one solution path. It is topologically two components (two connected walls).
It's cool.
http://www.mathworks.com/matlabcentral/fileexchange/27175-mazesolution
Usual solver is touch-always-the-right-hand-on-the-wall method, but this uses morphological operators.
I am not so sure, but the solution seems the following.
Assumption: Maze has only one solution path. It is topologically two components (two connected walls).
- Detect two wall components by a morphological operation.
- Expand two components by a morphological operation.
- 'AND' region of these two is the solution way.
It's cool.
Comments