Optimization

Integral is O(n) and point_dist increased to 0.02