Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Instructions Write a program that implements the A* algorithm to find a path from any two given nodes. in Java Problem Overview & Algorithm Description

Instructions Write a program that implements the A* algorithm to find a path from any two given nodes. in Java Problem Overview & Algorithm Description In a fully-observable environment where there are both pathable and blocked nodes, an agent must find a good path from their starting node to the goal node. The agent must use the A* algorithm to determine its path. For this program, you must use the Manhattan method for calculating the heuristic. Remember: your heuristic function is a representation of how good or close you are to the goal state. Program Requirements No graphics are required for this program but using them will help you with debugging and problem solving. Your environment should be a 15x15 tile-based world that randomly generates nodes that are unpathable (blocks) in 10% of the nodes. This should be done each time the program compiles ensuring that there are different environment makeups each run. The program should display the generated environment when the program runs, and should allow the user to select a starting node and goal node. This can be done via text input into the console or with a GUI. Once the start and goal nodes have been defined, the program should run the A* algorithm to find a path. The path should be displayed (series of [x,y] nodes, highlighting nodes, or actually moving the agent) if one exists, or a message indicating that a path could not be found. The user should be able to continue specifying starting and goal nodes after paths have been found.

Category

Value

Program is free of syntax and runtime errors

/ 10

Program uses A* and successfully finds a solution

/ 40

Program displays no path could be found if one does not exist

/ 10

Program generates and displays a 15x15 tile-based environment

/ 10

Blocks (unpathable tiles) are randomly placed in 10% of the node (not hard coded)

/ 5

User is able to specify and start and goal node

/ 10

The solution (path) is properly displayed

/ 10

Program utilizes an appropriate heuristic (Manhattan method)

/ 5

Program shows the agent moving along the path from start to goal

/5 (bonus)

Total Points

/ 100

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Systems Design Implementation And Management

Authors: Carlos Coronel, Steven Morris

14th Edition

978-0357673034

More Books

Students also viewed these Databases questions

Question

What do Dimensions represent in OLAP Cubes?

Answered: 1 week ago