pyFDN.is_uniallpass#

pyFDN.is_uniallpass(A, B, C, D, tol=1e-09)[source]#

Test whether the FDN is uniallpass (lossless with a diagonal Lyapunov matrix).

See Michaletzky, G. Factorization of discrete-time all-pass functions; and “Allpass Feedback Delay Networks” by Sebastian J. Schlecht.

Parameters:
  • A (ArrayLike) – Delay state-space matrices (feedback, input gain, output gain, direct).

  • B (ArrayLike) – Delay state-space matrices (feedback, input gain, output gain, direct).

  • C (ArrayLike) – Delay state-space matrices (feedback, input gain, output gain, direct).

  • D (ArrayLike) – Delay state-space matrices (feedback, input gain, output gain, direct).

  • tol (float) – Tolerance for zero and diagonal checks.

Returns:

True if the solution P of the discrete Lyapunov equation A P A' - P + B B' = 0 is diagonal and blkdiag(P, I) makes [A B; C D] unitary.

Return type:

bool

Notes

The Lyapunov equation only has a (unique, finite) solution when A is strictly stable. If A itself is lossless – as in the allpass-in-FDN structure, where the feedback matrix has all its eigenvalues on the unit circle – no such P exists, and the linear system scipy solves is exactly singular. Rather than let that surface as an ill-conditioned solve (which raises or returns garbage depending on the LAPACK build), the spectral radius is checked up front and the system reported as not uniallpass.