infidelity_stf

Graph.infidelity_stf(sample_times, hamiltonian, target, noise_operators=None, *, name=None)

Creates the total infidelity of a given system with a sampleable Hamiltonian.

See infidelity_pwc for information about the total infidelity created by this function.

Parameters
  • sample_times (np.ndarray(1D, real)) – The times at which the Hamiltonian and noise operators (if present) should be sampled for the integration. Must start with 0, be ordered, and contain at least one element.

  • hamiltonian (Stf) – The control Hamiltonian \(H_{\mathrm c}(t)\). You can provide either a single Hamiltonian or a batch of them.

  • target (Target) – The object describing the target gate \(U_\mathrm{target}\) and (optionally) the filter function projector \(P\). If you provide a batch of Hamiltonians, the function uses the same target for all the elements in the batch.

  • noise_operators (list[np.ndarray or Tensor or Stf], optional) – The perturbative noise operators \(\{N_j(t)\}\). The operators in the list can either be single operators or batches of them. If any of the noise operators or the Hamiltonian are batches, the batch shapes must all be broadcastable. You can omit this list if there are no noises.

  • name (str, optional) – The name of the node.

Returns

The total infidelity (operational infidelity plus filter function values) of the given system, with respect to the given target gate, at the last time in sample_times. If you provide a batch of Hamiltonians or noise operators, the function returns a batch of infidelities containing one infidelity for each Hamiltonian and list of noise operators in the input batches.

Return type

Tensor

See also

infidelity_pwc()

Corresponding operation for Pwc Hamiltonians.

target()

Define the target operation of the time evolution.

time_evolution_operators_stf()

Unitary time evolution operators for quantum systems with Stf Hamiltonians.