Bug with ArrayList

yes, and it never did.
so move it up and delete the right one

  if (k>momPos.size()-1) {
    while (momPos.size()>0) {
      for (int j=0; j<momPos.size(); j++) {
        momPos.remove(j);
      }
    }

    println("hei");
    k=0;
    points.remove(i);
    i++;

    for (float j=0.; j<=1.; j+=.01) {
      momPos.add(new PVector(lerp(points.get(i-1).pos.x, points.get(i).pos.x, j), lerp(points.get(i-1).pos.y, points.get(i).pos.y, j)));
    }
  }