Method | Description | |
---|---|---|
CalculateCentroid ( IList |
Calculates the centroid for the given set of points. For the Euclidean distance metric the centroid is given by calculating the componentwise mean over the set of points.
|
|
CalculateCentroidParallel ( IList |
Parallelized version of CalculateCentroid().
|
|
MeasureDistance ( |
Tests if the distance between two positions is less than some threshold. A simple way of implementing this method would be to calculate the distance between the two coordinates and test if it is less than the threshold. However, that approach requires that all of the elements in both CoordinateVectors be fully compared. We can improve performance in the general case by testing if the threshold has been passed after each vector element comparison thus allowing an early exit from the method for many calls. Further to this, we can begin comparing from the ends of the vectors where differences are most likely to occur.
|
|
MeasureDistance ( |
Measures the distance between two positions.
|
public CalculateCentroid ( IList |
||
coordList | IList |
|
return |
public CalculateCentroidParallel ( IList |
||
coordList | IList |
|
return |
public MeasureDistance ( |
||
p1 | ||
p2 | ||
threshold | double | |
return | bool |
public MeasureDistance ( |
||
p1 | ||
p2 | ||
return | double |