Algorithm | Core Idea (How it chooses the next step/node) | Original Work (Citation) | Key Strengths & Weaknesses | Best Use Case |
---|---|---|---|---|
Discrete/Grid-Based Search | ||||
Dijkstra's | Expands the node with the lowest actual cost from the start, g(n). | Dijkstra, E. W. (1959). A note on two problems in connexion with graphs. | Strengths: Simple, guaranteed optimal. Weaknesses: Uninformed search, explores in all directions, slow in large spaces. |
Finding the provably shortest path in simple, positively weighted graphs where no heuristic is available. |
Greedy Best-First | Expands the node with the lowest estimated cost to the goal, h(n). | Doran, J. E., & Michie, D. (1966). Experiments with the Graph Traverser program. | Strengths: Very fast. Weaknesses: Not optimal, can be easily misled by poor heuristics into long or dead-end paths. |
When finding any path quickly is far more important than finding the best path. |
A* (A-Star) | Expands the node with the lowest sum |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
import pandas as pd | |
def numpy_to_latex( | |
arr: np.ndarray, | |
columns=None, | |
index=False, | |
caption=None, | |
label=None, | |
float_format="%.3f", |