Geometry IV: nonregular Riemannian geometry