0
$\begingroup$

The scipy.linalg.qz function implements generalized Schur decomposition for a pair of matrices A, B such that (A, B) = (Q @ AA @ Z*, Q @ BB @ Z*), where AA is quasi upper triangular and BB is upper triangular. The documentation says for the matrix AA "1x1 blocks correspond to real generalized eigenvalues and 2x2 blocks are ‘standardized’ by making the corresponding elements of BB have the form: [[a 0], [0, b]]". I was wondering if someone is aware of how this standardization is done?

$\endgroup$
2
  • $\begingroup$ Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking. $\endgroup$
    – Community Bot
    Commented Sep 20, 2022 at 16:57
  • 2
    $\begingroup$ This is a wrapper for the LAPACK routine CGGES. Have you looked at the LAPACK user's guide and LAPACK Working Notes for more information about the algorithm used by this routine? $\endgroup$ Commented Sep 20, 2022 at 16:58

1 Answer 1

2
$\begingroup$

The documentation is not super clear on this. But I happen to have written some of that code.

This is done using a small SVD.

Before standardization, the 2x2 block will be:

$ (A,B) = \left(\begin{bmatrix} a_{11} & a_{12} \\ a_{21} & a_{22} \end{bmatrix}, \begin{bmatrix} b_{11} & b_{12} \\ 0 & b_{22} \end{bmatrix} \right) $

Then an SVD is calculated of $B$. Because it is a 2x2 upper triangular matrix, this can be done using 2 Givens rotations (see dlasv2) and optionally some sign inversions to give: $UBV = D$, where $D$ is diagonal with positive elements.

Then the final standardized block is $U(A,B)V$.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.