Fixed problem with spline and discontinuities in rho