alecjacobson / geometry-processing-curvature

Curvature assignment for Geometry Processing course
https://github.com/alecjacobson/geometry-processing
Mozilla Public License 2.0
148 stars 73 forks source link

eigendecomposition of shape operator #18

Open aPToul opened 6 years ago

aPToul commented 6 years ago

During principal curvature estimation (via the shape operator), I am having some trouble getting real values.

The EigenSolver for eigendecomposition finds complex values / vectors, but from the argument in the ReadMe, the shape operator is diagonalizable with real values, since curvature is real and extremal.

I'm wondering if there's a way to encourage the solver to find the closest real valued decomposition (I haven't had a chance to read up on the fundamental forms to verify whether they are indeed always decomposable this way, but I guess it should be the case for the quadratic form).

aPToul commented 6 years ago

Looks like Eigen::SelfAdjointEigenSolver PCA_2D could be promising, but it assumes our operator is self adjoint. This is fine since the product of two symmetric matrices (L * R) is symmetric, and the inverse of a symmetric matrix (L) is symmetric. I think this will work.