StarkRamseyXY#

class StarkRamseyXY(physical_qubits, backend=None, **experiment_options)[source]#

A sign-sensitive experiment to measure the frequency of a qubit under a pulsed Stark tone.

Overview

This experiment is a variant of RamseyXY with a pulsed Stark tone and consists of the following two circuits:

(Ramsey X)  The pulse before measurement rotates by pi-half around the X axis

         ┌────┐┌────────┐┌───┐┌───────────────┐┌────────┐┌────┐┌─┐
      q: ┤ √X ├┤ StarkV ├┤ X ├┤ StarkU(delay) ├┤ Rz(-π) ├┤ √X ├┤M├
         └────┘└────────┘└───┘└───────────────┘└────────┘└────┘└╥┘
    c: 1/═══════════════════════════════════════════════════════╩═
                                                                0

(Ramsey Y) The pulse before measurement rotates by pi-half around the Y axis

         ┌────┐┌────────┐┌───┐┌───────────────┐┌───────────┐┌────┐┌─┐
      q: ┤ √X ├┤ StarkV ├┤ X ├┤ StarkU(delay) ├┤ Rz(-3π/2) ├┤ √X ├┤M├
         └────┘└────────┘└───┘└───────────────┘└───────────┘└────┘└╥┘
    c: 1/══════════════════════════════════════════════════════════╩═
                                                                   0

In principle, the sequence is a variant of RamseyXY circuit. However, the delay in between √X gates is replaced with an off-resonant drive. This off-resonant drive shifts the qubit frequency due to the Stark effect and causes it to accumulate phase during the Ramsey sequence. This frequency shift is a function of the offset of the Stark tone frequency from the qubit frequency and of the magnitude of the tone.

Note that the Stark tone pulse (StarkU) takes the form of a flat-topped Gaussian envelope. The magnitude of the pulse varies in time during its rising and falling edges. It is difficult to characterize the net phase accumulation of the qubit during the edges of the pulse when the frequency shift is varying with the pulse amplitude. In order to simplify the analysis, an additional pulse (StarkV) involving only the edges of StarkU is added to the sequence. The sign of the phase accumulation is inverted for StarkV relative to that of StarkU by inserting an X gate in between the two pulses.

This technique allows the experiment to accumulate only the net phase during the flat-top part of the StarkU pulse with constant magnitude.

User manual

AC Stark Effect

Analysis class reference

qiskit_experiments.library.characterization.RamseyXYAnalysis

Experiment options

These options can be set by the set_experiment_options() method.

Options
  • Defined in the class StarkRamseyXY:

    • stark_amp (float)

      Default value: 0.0
      A single float parameter to represent the magnitude of Stark tone and the sign of expected Stark shift. See Stark tone implementation in Qiskit for details.
    • stark_channel (PulseChannel)

      Default value: None
      Pulse channel to apply Stark tones. If not provided, the same channel with the qubit drive is used. See Stark tone channel for details.
    • stark_freq_offset (float)

      Default value: 80000000.0
      Offset of Stark tone frequency from the qubit frequency. This offset should be sufficiently large so that the Stark pulse does not Rabi drive the qubit. See Stark tone frequency for details.
    • stark_sigma (float)

      Default value: 1.5e-08
      Gaussian sigma of the rising and falling edges of the Stark tone, in seconds.
    • stark_risefall (float)

      Default value: 2
      Ratio of sigma to the duration of the rising and falling edges of the Stark tone.
    • min_freq (float)

      Default value: 5000000.0
      Minimum frequency that this experiment is guaranteed to resolve. Note that fitter algorithm RamseyXYAnalysis of this experiment is still capable of fitting experiment data with lower frequency.
    • max_freq (float)

      Default value: 100000000.0
      Maximum frequency that this experiment can resolve.
    • delays (list[float])

      Default value: None
      The list of delays if set that will be scanned in the experiment. If not set, then evenly spaced delays with interval computed from min_freq and max_freq are used. See StarkRamseyXY.delays() for details.
  • Defined in the class BaseExperiment:

    • max_circuits (Optional[int])

      Default value: None
      The maximum number of circuits per job when running an experiment on a backend.

See also

qiskit_experiments.library.characterization.ramsey_xy.RamseyXY

Initialization

Create new experiment.

Parameters:
  • physical_qubits (Sequence[int]) – Index of physical qubit.

  • backend (Backend | None) – Optional, the backend to run the experiment on.

  • experiment_options – Experiment options. See the class documentation or self._default_experiment_options for descriptions.

Attributes

analysis#

Return the analysis instance for the experiment

backend#

Return the backend for the experiment

experiment_options#

Return the options for the experiment.

experiment_type#

Return experiment type.

num_qubits#

Return the number of qubits for the experiment.

physical_qubits#

Return the device qubits for the experiment.

run_options#

Return options values for the experiment run() method.

transpile_options#

Return the transpiler options for the run() method.

Methods

circuits()[source]#

Create circuits.

Returns:

A list of circuits with a variable delay.

Return type:

list[QuantumCircuit]

config()#

Return the config dataclass for this experiment

Return type:

ExperimentConfig

copy()#

Return a copy of the experiment

Return type:

BaseExperiment

classmethod from_config(config)#

Initialize an experiment from experiment config

Return type:

BaseExperiment

job_info(backend=None)#

Get information about job distribution for the experiment on a specific backend.

Parameters:

backend (Backend) – Optional, the backend for which to get job distribution information. If not specified, the experiment must already have a set backend.

Returns:

A dictionary containing information about job distribution.

  • ”Total number of circuits in the experiment”: Total number of circuits in the experiment.

  • ”Maximum number of circuits per job”: Maximum number of circuits in one job based on backend and experiment settings.

  • ”Total number of jobs”: Number of jobs needed to run this experiment on the currently set backend.

Return type:

dict

Raises:

QiskitError – if backend is not specified.

parameterized_circuits()[source]#

Create circuits with parameters for Ramsey XY experiment with Stark tone.

Returns:

Quantum template circuits for Ramsey X and Ramsey Y experiment.

Return type:

tuple[QuantumCircuit, …]

parameters()[source]#

Delay values to use in circuits.

Note

The delays are computed with the min_freq and max_freq experiment options. The maximum point is computed from the min_freq to guarantee the result contains at least one Ramsey oscillation cycle at this frequency. The interval is computed from the max_freq to sample with resolution such that the Nyquist frequency is twice max_freq.

Returns:

The list of delays to use for the different circuits based on the experiment options.

Raises:

ValueError – When min_freq is larger than max_freq.

Return type:

ndarray

run(backend=None, analysis='default', timeout=None, **run_options)#

Run an experiment and perform analysis.

Parameters:
  • backend (Backend | None) – Optional, the backend to run the experiment on. This will override any currently set backends for the single execution.

  • analysis (BaseAnalysis | None) – Optional, a custom analysis instance to use for performing analysis. If None analysis will not be run. If "default" the experiments analysis() instance will be used if it contains one.

  • timeout (float | None) – Time to wait for experiment jobs to finish running before cancelling.

  • run_options – backend runtime options used for circuit execution.

Returns:

The experiment data object.

Raises:

QiskitError – If experiment is run with an incompatible existing ExperimentData container.

Return type:

ExperimentData

set_experiment_options(**fields)[source]#

Set the experiment options.

Parameters:

fields – The fields to update the options

Raises:

AttributeError – If the field passed in is not a supported options

set_run_options(**fields)#

Set options values for the experiment run() method.

Parameters:

fields – The fields to update the options

See also

The Setting options for your experiment guide for code example.

set_transpile_options(**fields)#

Set the transpiler options for run() method.

Parameters:

fields – The fields to update the options

Raises:

QiskitError – If initial_layout is one of the fields.

See also

The Setting options for your experiment guide for code example.