routing
Class Router

java.lang.Object
  extended by routing.Router

public class Router
extends java.lang.Object


Field Summary
static int BRANCH_THRESHOLD
           
static int COMPETITIVE_ANGLE_THRESHOLD
           
static double FORTY_FIVE_DEGREES
           
static double HUNDRED_EIGHTY_DEGREES
           
static double MEDIUM_COMPLEXITY_INCREMENT
           
static double MINOR_COMPLEXITY_INCREMENT
           
static double NINETY_DEGREES
           
private  int optimizationFactor
           
private  java.util.HashMap<DecisionPoint,Edge> pathMap
           
private  java.util.HashSet<DecisionPoint> points
           
static double TWO_HUNDRED_SEVENTY_DEGREES
           
 
Constructor Summary
Router(java.util.ArrayList<DecisionPoint> points, int optimizationFactor)
           
 
Method Summary
 void calculateDecisionPointComplexities(java.util.ArrayList<DecisionPoint> points)
           
private  double getAngleBetweenDecisionPoints(DecisionPoint point1, DecisionPoint point2)
           
private  double getAngleBetweenPoints(double point1X, double point1Y, double point2X, double point2Y)
           
private  double getDecisionPointComplexity(DecisionPoint dp)
           
private  double getHeuristicValue(DecisionPoint dp, DecisionPoint goal)
           
 int getNumDecisionPoints(DecisionPoint dp)
           
 Path getPath(DecisionPoint start, DecisionPoint goal)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

optimizationFactor

private int optimizationFactor

BRANCH_THRESHOLD

public static final int BRANCH_THRESHOLD
See Also:
Constant Field Values

COMPETITIVE_ANGLE_THRESHOLD

public static final int COMPETITIVE_ANGLE_THRESHOLD
See Also:
Constant Field Values

MEDIUM_COMPLEXITY_INCREMENT

public static final double MEDIUM_COMPLEXITY_INCREMENT
See Also:
Constant Field Values

MINOR_COMPLEXITY_INCREMENT

public static final double MINOR_COMPLEXITY_INCREMENT
See Also:
Constant Field Values

FORTY_FIVE_DEGREES

public static final double FORTY_FIVE_DEGREES
See Also:
Constant Field Values

NINETY_DEGREES

public static final double NINETY_DEGREES
See Also:
Constant Field Values

HUNDRED_EIGHTY_DEGREES

public static final double HUNDRED_EIGHTY_DEGREES
See Also:
Constant Field Values

TWO_HUNDRED_SEVENTY_DEGREES

public static final double TWO_HUNDRED_SEVENTY_DEGREES
See Also:
Constant Field Values

points

private java.util.HashSet<DecisionPoint> points

pathMap

private java.util.HashMap<DecisionPoint,Edge> pathMap
Constructor Detail

Router

public Router(java.util.ArrayList<DecisionPoint> points,
              int optimizationFactor)
Method Detail

getPath

public Path getPath(DecisionPoint start,
                    DecisionPoint goal)

calculateDecisionPointComplexities

public void calculateDecisionPointComplexities(java.util.ArrayList<DecisionPoint> points)

getHeuristicValue

private double getHeuristicValue(DecisionPoint dp,
                                 DecisionPoint goal)
Parameters:
dp -
goal -
Returns:

getDecisionPointComplexity

private double getDecisionPointComplexity(DecisionPoint dp)

getNumDecisionPoints

public int getNumDecisionPoints(DecisionPoint dp)
Parameters:
dp -
Returns:

getAngleBetweenPoints

private double getAngleBetweenPoints(double point1X,
                                     double point1Y,
                                     double point2X,
                                     double point2Y)

getAngleBetweenDecisionPoints

private double getAngleBetweenDecisionPoints(DecisionPoint point1,
                                             DecisionPoint point2)