Skip to content

matfree.pinv

matfree.pinv

Pseudo-inverses of linear operators.

matfree.pinv.pinv_tall(Av: Callable, vA: Callable, *, solve: Callable) -> Callable

Construct the (Moore-Penrose) pseudo-inverse of a full-rank, ''tall'' matrix.

Implemented as a left-inverse, \(A^\dagger := A^* (A A^*)^{-1}\), which is applicable if \(A\) has full column-rank.

Parameters:

  • Av (Callable) –

    Matrix-vector product function.

  • vA (Callable) –

    Vector-matrix product function.

  • solve (Callable) –

    Solution of a linear system. Maps a matrix-vector production function and a right-hand-side vector to the solution of the linear system.

Returns:

  • Callable

    Matrix-vector product function that implements the pseudo-inverse of the matrix-vector product function Av.

matfree.pinv.pinv_wide(Av: Callable, vA: Callable, *, solve: Callable) -> Callable

Construct the (Moore-Penrose) pseudo-inverse of a full-rank, ''wide'' matrix.

Implemented as a right-inverse, \(A^\dagger := (A^* A)^{-1} A^*\), which is applicable if \(A\) has full row-rank.

Parameters:

  • Av (Callable) –

    Matrix-vector product function.

  • vA (Callable) –

    Vector-matrix product function.

  • solve (Callable) –

    Solution of a linear system. Maps a matrix-vector production function and a right-hand-side vector to the solution of the linear system.

Returns:

  • Callable

    Matrix-vector product function that implements the pseudo-inverse of the matrix-vector product function Av.