Package org.graph4j.shortestpath
Class AStarEuclideanEstimator
java.lang.Object
org.graph4j.shortestpath.AStarEuclideanEstimator
- All Implemented Interfaces:
AStarEstimator
Euclidean distance.
- Author:
- Cristian Ivan, Cristian Frăsinaru
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondoubleestimate(int vertex, int target) Estimates the cost to reach the target from the given node.
-
Constructor Details
-
AStarEuclideanEstimator
public AStarEuclideanEstimator(int gridSize)
-
-
Method Details
-
estimate
public double estimate(int vertex, int target) Description copied from interface:AStarEstimatorEstimates the cost to reach the target from the given node.- Specified by:
estimatein interfaceAStarEstimator- Parameters:
vertex- The current vertex index.target- The target vertex index.- Returns:
- The estimated cost to reach the target.
-