fixed a bug for calculating persistence length for every s along contour length