r"""Generate the operator matrix with quadrants

    .. math::

       \begin{pmatrix} A B \\ C D \end{pmatrix}

    Args:
        A (Matrix): Matrix of shape ``(n, m)``
        B (Matrix): Matrix of shape ``(n, k)``
        C (Matrix): Matrix of shape ``(l, m)``
        D (Matrix): Matrix of shape ``(l, k)``

    Returns:
        Matrix: The combined block matrix ``[[A, B], [C, D]]``.

def block_matrix(A, B, C, D):
    r"""Generate the operator matrix with quadrants

    .. math::

       \begin{pmatrix} A B \\ C D \end{pmatrix}

    Args:
        A (Matrix): Matrix of shape ``(n, m)``
        B (Matrix): Matrix of shape ``(n, k)``
        C (Matrix): Matrix of shape ``(l, m)``
        D (Matrix): Matrix of shape ``(l, k)``

    Returns:
        Matrix: The combined block matrix ``[[A, B], [C, D]]``.
    """
    return vstackm((hstackm((A, B)), hstackm((C, D))))