Corrected ellipse perimeter calculation.