8-Puzzle Solver


This is a graph search program created as midterm project for Montclair State University's Spring 2016 CSIT 357: Artificial Intelligence course. The program implements a range of Uninformed and Informed search agents to solve an 8-puzzle. There is a set of preset puzzles, but user can also input a custom puzzle. All search agents can run as a tree or a graph search, and two Heuristics are offered for the use of Informed agents.

The search agents implemented are:

Uninformed Agents

  • Breadth First Search
  • Uniform Cost Search
  • Depth First Search
  • Depth Limited Search
  • Iterator Deepening Search

Informed Agents

  • Greedy Best First Search
  • A* Search

Heuristics

  • Misplaced Tile
  • Manhattan Distance

The program utilizes class hierarchy with the core of the program consisting of abstract classes. The goal of the design is for the program to be scalable to add more search agents and adoptable to solve other types of tree and graph search problems.

Download Executable Jar

*Requires JRE 1.8. Execute "java -jar 8-PuzzleSolver.jar" from Command Prompt in the downloaded folder to run the program.

Download Source Code

Back to Main

8-Piece Puzzle Solver

Scribbler Robot Image Detection


This is an image-detection program written for a Scribbler2 robot with an IPRE Fluke2 add-on board for the final project in Montclair State University's Fall 2016 CSIT 431: Artificial Intelligence course. Scribbler2 is a simple 2-wheeled robot 2 IR obstacle sensors, 2 IR line-detection sensors, and 3 indicator lights that is used primarily to draw figures (hence the name) using a remote or pre-programmed routine. The Fluke2 board adds a camera, 3 additional IR obstacle sensors, a battery voltage sensor, and Calico, a framework that supports a wide range of languages including Python and provides Myro, a library for robot control.

The goal of this project was to have a Scribbler be able to detect and follow another Scribbler robot using its camera to detect the color and the shape of the red box on top of the first robot. The image detection was implemented using the blob-detection function from the Myro library. The algorithm uses a grid to try to keep the box centered in the camera's field of view. By counting the pixels that falls in each section of the grid, the follower robot is able to adjust not only horizontally when the target veers left or right, but also maintain its distance by moving backward or forward when the pixel count deviates above or below the desired range.

The program was written in Python using IPRE's Calico framework with the Myro library.

Download Code

For more videos on this project and my other Scribbler assignments from CSIT431, go to YouTube channel.

Back to Main