quara.objects.qoperation_typical module

generate_effective_lindbladian_object(gate_name, object_name, dims=None, ids=None, c_sys=None, is_physicality_required=True)[source]

Return an effective-llindbladian-related object.

Parameters
  • gate_name (str) – The list of valid gate_name is given by quara.objects.gate_typical.get_gate_names().

  • object_name (str) – The list of valid object_name is given by get_effective_lindbladian_object_names().

  • dims (List[int] = None, Optional) – To be given for gate_name = ‘identity’

  • ids (List[int] = None, Optional) – This is a list of elmental system’s ids. To be given for specific asymmetric multi-partite gates For example, in the case of gate_name = ‘cx’, id[0] is for the id of the control qubit and id[1] is for the id of the target qubit.

  • c_sys (CompositeSystem = None, Optional) – To be given for object_name = ‘effective_lindbladian’

  • is_physicality_required (bool = True) – whether the generated object is physicality required, by default True

Returns

np.ndarray
Hamiltonian vector for object_name = ‘hamiltonian_vec’

Real vector (The representaiton matrix basis is chosen to be Hermitian)

Hamiltonian matrix for object_name = ‘hamiltonian_mat’

Complex matrix

HS matrix for object_name = ‘effective_lindbladian_mat’

Reak matrix

”EffectiveLindbladian”

EffectiveLindbladian class for object_name = ‘effective_lindbladian’

Return type

Union[np.ndarray, “EffectiveLindbladian”]

generate_gate_object(gate_name, object_name, dims=None, ids=None, c_sys=None, is_physicality_required=True)[source]

Return a gate-related object.

Parameters
  • gate_name (str) – The list of valid gate_name is given by quara.objects.gate_typical.get_gate_names().

  • object_name (str) – The list of valid object_name is given by get_gate_object_names().

  • dims (List[int] = None, Optional) – To be given for gate_name = ‘identity’

  • ids (List[int] = None, Optional) – This is a list of elmental system’s ids. To be given for specific asymmetric multi-partite gates For example, in the case of gate_name = ‘cx’, id[0] is for the id of the control qubit and id[1] is for the id of the target qubit.

  • c_sys (CompositeSystem = None, Optional) – To be given for object_name = ‘gate’

  • is_physicality_required (bool = True) – whether the generated object is physicality required, by default True

Returns

np.ndarray
Unitary matrix for object_name = ‘unitary_mat’

Complex matrix

HS matrix for object_name = ‘gate_mat’

Real matrix

”Gate”

Gate class for object_name = ‘gate’

Return type

Union[np.ndarray, “Gate”]

generate_mprocess_object(mprocess_name, object_name, c_sys=None, is_physicality_required=True)[source]
Parameters
Return type

Union[numpy.ndarray, quara.objects.gate.Gate]

generate_povm_object(povm_name, object_name, c_sys=None, is_physicality_required=True)[source]
Parameters
generate_qoperation(mode, name, c_sys, ids=None, is_physicality_required=True)[source]
Parameters
Return type

quara.objects.qoperation.QOperation

generate_qoperation_depolarized(mode, name, c_sys, error_rate, ids=None, is_physicality_required=True)[source]
Parameters
Return type

quara.objects.qoperation.QOperation

generate_qoperation_object(mode, name, object_name, dims=None, ids=None, c_sys=None, is_physicality_required=True)[source]
Parameters
generate_state_ensemble_object(state_ensemble_name, object_name, c_sys=None)[source]
Parameters
Return type

Union[numpy.ndarray, quara.objects.gate.Gate]

generate_state_object(state_name, object_name, c_sys=None, is_physicality_required=True)[source]
Parameters
get_effective_lindbladian_object_names()[source]

Return the list of valid effective-lindbladian-related object names.

Return type

List[str]

get_gate_object_names()[source]

Return the list of valid gate-related object names.

Return type

List[str]