densityOperation

densityOperation(D)

Performs the operation on the density matrix

Parameters:
  • psi : ndarray with shape = (2^nQubits, 2^nQubits)

    The state to apply the operation to in density form.

  • gate : ndarray with shape = (2^nQubits, 2^nQubits)

    The operation to apply to the state.

Returns:
  • psi : ndarray with shape = (2^nQubits, 2^nQubits)

    The state with the operation applied.


Contact

In case you have any further questions about the Python code, you should direct them to Scott Turro or Joey Shallat.