Skip to content

adjoint

qoptcraft.operators.adjoint

adjoint_evol(hamiltonian, unitary)

Compute the Heisenberg evolution of a hamiltonian. This is done via the adjoint action of the unitary group on the algebra of hermitian matrices.

Parameters:

Name Type Description Default
hamiltonian NDArray

matrix of the hamiltonian.

required
unitary NDArray

matrix of the unitary.

required

Returns:

Name Type Description
NDArray NDArray

evolved hamiltonian.

Source code in qoptcraft/operators/adjoint.py
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
def adjoint_evol(hamiltonian: NDArray, unitary: NDArray) -> NDArray:
    """Compute the Heisenberg evolution of a hamiltonian.
    This is done via the adjoint action of the unitary group
    on the algebra of hermitian matrices.

    Args:
        hamiltonian (NDArray): matrix of the hamiltonian.
        unitary (NDArray): matrix of the unitary.

    Returns:
        NDArray: evolved hamiltonian.
    """
    return unitary @ hamiltonian @ unitary.conj().T