
where \(\lambda _{min}\)  and \(\lambda _{max}\)  are computed from the smallest and the largest generalized eigenvalues of \(( {\overline{A}} _n,B_n)\) .
This optimal parameter \(\lambda _{0}\)  balances the loss \(\mathcal {E}\)  and the regularization (see [1]} for more details).
In practice, instead of computing the second order derivatives, we compute the curvature by the reciprocal of the radius of the interior circle of three consecutive pointsAre Mjaavatten (2022). Curvature of a 1D curve in a 2D or 3D space (https://www.mathworks.com/matlabcentral/fileexchange/69452-curvature-of-a-1d-curve-in-a-2d-or-3d-space), MATLAB Central File Exchange..
