Remove CurveMatrix completely and any lapack references.