performOperation

performOperation(psi, g)

Performs the operations on the input State.

Parameters:
  • psi : ndarray

    The input state to do the operation on. Can be a pure state or a density matrix.

  • g : ndarray with shape = (num operations, 2^numQubits, 2^numQubits)

    The operations you would like to be done. Can be one operation or an array of operations.

Returns:
  • p : ndarray

    The output state after the operations. Will retain the input form.


Contact

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