Kaushik Bhattacharjee | Colorado State University - CS 440 - Artificial Intelligence Project
Given any Rubik's Cube state, return a list of moves to solve the Rubik's RubikCube using Korf's IDEA* Algorithm.
- Represent a 3D rubikCube in a 2D state
- Generate 3 pattern databases: corner cubies, edge cubies set 1, edge cubies set 2
- Perform Iterative Deepening astar (IDA*) search on the possible moves using the 3 above pattern databases as the heuristic look up
- Return an optimal solution in the form of the face to turn and how many clockwise turns to make
- Handled only clockwise turns of a face
Compile the Java source files in src directory:
cd src
javac *.java
To generate the heuristic lookup tables, run below commands in src directory
chmod 755 createHeuristics.sh
./createHeuristics.sh
To solve a rubikCube from a file run following command:
java -Xmx2g RubikCube "input file path"