ut3_orthogonality_residual#

t3toolbox.backend.ut3_orthogonalization.ut3_orthogonality_residual(data, side)#
def ut3_orthogonality_residual(
        data: UT3Data,
        side: str,  # 'left' or 'right'
) -> NDArray:  # shape = stack_shape; max abs deviation of the masked cores from orthonormality, per element

Uniform analog of t3_orthogonality_residual(): non-enforcing check of left/right-orthogonal form (Tucker supercores down-orthogonal AND TT supercores left/right-orthogonal), per stack element.

Compares each masked supercore’s Gram against diag(mask) (the masked rows/cols are zero, so the identity is restricted to the real block). The boundary TT core (last for left, first for right) is the center remainder and is not checked. Reduced over the non-stack axes (the leading mode index d and the two gram axes), so the result has shape stack_shape.

Parameters:
  • data (UT3Data)

  • side (str)

Return type:

NDArray