fixed sine/tangent mistake in factor of safety and curvature friction