Class AStarSearch<V,W>
java.lang.Object
org.episteme.core.mathematics.discrete.AStarSearch<V,W>
A* search algorithm for heuristic-guided shortest path finding.
More efficient than Dijkstra when a good heuristic is available. Requires non-negative edge weights.
- Since:
- 1.0
- Author:
- Silvere Martin-Michiellot, Gemini AI (Google DeepMind)
-
Constructor Summary
ConstructorsConstructorDescriptionAStarSearch(GraphWeightAdapter<W> weightAdapter, AStarHeuristic<V, W> heuristic) -
Method Summary
Modifier and TypeMethodDescriptionFinds shortest path from source to goal using A* search.static <V> AStarSearch<V, Double> ofDouble(AStarHeuristic<V, Double> heuristic)
-
Constructor Details
-
AStarSearch
-
-
Method Details
-
ofDouble
-
findPath
Finds shortest path from source to goal using A* search.- Parameters:
graph- the graphsource- source vertexgoal- goal vertex- Returns:
- result containing path and distance
-