p2 = p1;
}
}
private void sortStars(){
EuclidianSimple2D d = new EuclidianSimple2D();
LinkedList<Star> newStars = new LinkedList<>();
Star previous = centroid;
Star closest = null;
double dist;
while(!stars.isEmpty()){
double min = Double.MAX_VALUE;
for(Star s : stars){
dist = d.get(s, previous);
if(dist < min){
min = dist;
closest = s;
}
}