Giter Site home page Giter Site logo

gadgil-devashri / 8-puzzle-a-star-search Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 2.0 255 KB

Repository for programming project one under ITCS 6150 Intelligent Systems under Dr. Dewan Ahmad for the fall 2021 semester. The aim is to solve the 8-puzzle problem using an A star search algorithm based on the heuristic function chosen by the user. The programming language chosen for this project is Python 3

Python 100.00%
8-puzzle-problem a-star-search heuristic-search-algorithms python3 manhatten-distance misplaced-tiles

8-puzzle-a-star-search's Introduction

8 Puzzle problem using A* Search

Group Members

  • Devashri Gadgil
  • Varad Deshpande
  • Akshay Bheda

Problem Statement

The 8-puzzle problem is a puzzle invented by Noyes Palmer Chapman. It is played on a 3-by-3 grid with 8 square blocks labeled 1 through 8 and a blank square. The goal is to rearrange the blocks so that they are in order. We are permitted to slide blocks horizontally or vertically into the blank square.The following shows a sequence of legal moves from an initial board position to the goal position.

Instructions to execute the code:

Prerequisites:

  • Make sure you have python installed.
  • Make sure you have numpy installed.
  • When you import the code in an IDE make sure there are no errors on the imports (numpy and copy).

Steps to run the program:

  • Clone the repository
  • Go to the folder containing the code.
  • Open the terminal and and run command- py A_star.py
  • While inputting the initial and goal state, input them as a matrix. For Example, if you want to input a goal state 1 2 3 4 5 6 7 8 0, you should input as matrix as follows: 123 (3 inputs per line)
  • Select the heuristic of your choice. If you input any value besides 1, Manhattan heuristic will get selected automatically.

8-puzzle-a-star-search's People

Contributors

gadgil-devashri avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.