where \(A_d, B_d, C_d\)  are a state-space realization of \(X^d(s)\)  [1]}. The Lyapunov equation in () is differentiable [2]} with respect to admittance parameters \(M_i, D_i, K_i\) , allowing the efficient calculation of the Jacobian and Hessian of this objective for the optimization problem. Note that the naïve solution of (), by vectorizing and a linear solve may have numerical issues when the matrices are poorly conditioned, in such case using specialized solvers like Bartels-Stewart can improve performance.
