class DouglasPeucker {

    static void removeNaN(PointList pointList) {
        int curr = 0;
        for (int i = 0; i < pointList.size(); i++) {
            if (!Double.isNaN(pointList.getLatitude(i))) {
                pointList.set(curr, pointList.getLatitude(i), pointList.getLongitude(i), pointList.getElevation(i));
                curr++;
            }
        }
        pointList.trimToSize(curr);
    }

    public  DouglasPeucker();

}