quchip.control.drive

Classical control lines and their quantum Hamiltonian couplings.

A drive builds the complete scheduled analytic signal, then maps its physical I/Q quadratures to target-local quantum operators. Control equipment may alter that signal before the Hamiltonian mapping. Projection, frames, approximation, embedding, unit conversion, and backend lowering remain engine responsibilities.

Conventions:

  • Frequencies are GHz; times are ns.

  • Operators are returned in the device’s authored local basis — embedding into the full chip Hilbert space is the engine’s job.

References

  • Krantz et al., A quantum engineer’s guide to superconducting qubits, APR 6, 021318 (2019) — microwave control of transmons (Sec. IV).

  • Koch et al., PRA 76, 042319 (2007) — charge vs flux noise and drives in the transmon regime.

Classes

BaseDrive([target, label])

Base class for classical control lines attached to one quantum target.

ChargeDrive([target, label])

Microwave charge drive on a transmon-like device.

CouplingDrive([target, label])

Drive authoring base for a two-endpoint coupling Hamiltonian.

DeviceDrive([target, label])

Drive authoring base for a device-local Hamiltonian.

FluxDrive([target, label])

Real-valued flux drive coupling to \(\hat n\).

ParametricDrive([target, label])

Control line pumping a modulable coupling's strength δ(t) in GHz.

PhaseDrive([target, label])

Microwave phase drive coupling to \(\hat a + \hat a^\dagger\).

class quchip.control.drive.BaseDrive(target=None, *, label=None, **params)[source]

Bases: Registrable

Base class for classical control lines attached to one quantum target.

Drives own their local Hamiltonian contribution and are auto-labelled from their _type_prefix (e.g. charge_0, flux_0) unless label is given. Subclasses are auto-registered for serialization via the shared Registrable mixin.

Parameters:
  • target (BaseDevice, BaseCoupling, str, or None) – Target accepted by the concrete drive. A DeviceDrive targets a device; a CouplingDrive targets a coupling. The target may be connected later or resolved by label through Chip.

  • label (str | None) – Optional explicit label; otherwise auto-generated.

  • params (Any)

Examples

>>> from quchip import DuffingTransmon, ChargeDrive
>>> q = DuffingTransmon(freq=5.0, anharmonicity=-0.25, levels=3)
>>> drive = ChargeDrive(target=q)
>>> drive.device_label == q.label
True
target: Any
label: Any
connect(target)[source]

Attach this device-drive implementation to target.

If previously attached, the drive is removed from the old device’s _connected_drives list. CouplingDrive overrides this handshake because couplings do not own connected-drive lists.

Parameters:

target (Any)

Return type:

None

parameter_values()[source]

Return drive-owned bindable values declared by the subclass.

Return type:

dict[str, Any]

set_parameter_value(name, value)[source]

Apply one drive-owned value on an isolated drive copy.

Parameters:
Return type:

None

property device_label: str | None

Label of the connected device, or None if unconnected.

property target_label: str | None

Label of this drive’s target, or None if unconnected.

Device-target drives alias device_label; ParametricDrive resolves its coupling target instead.

dissipation(target, op, p)[source]

Return target-local Lindblad channels contributed by this line.

Parameters:
Return type:

tuple[CollapseChannel, …]

signal(pulse, target)[source]

Build the complete scheduled analytic signal for one pulse.

Parameters:
Return type:

AnalyticSignal

hamiltonian(target, signal)[source]

Map a delivered classical signal to target-local quantum physics.

Parameters:
Return type:

Any

physics_notes()[source]

Return human-readable declarations of this drive’s approximations.

Subclasses append their physical coupling details to the shared target line. Aggregated by Chip.physics_notes().

Return type:

list[str]

copy(*, target=None)[source]

Return a shallow copy, optionally rebound to a new target.

Parameters:

target (BaseDevice | None)

Return type:

BaseDrive

to_dict()[source]

Serialize into a JSON-safe dictionary.

Return type:

dict[str, Any]

class quchip.control.drive.DeviceDrive(target=None, *, label=None)[source]

Bases: BaseDrive

Drive authoring base for a device-local Hamiltonian.

Parameters:
class quchip.control.drive.CouplingDrive(target=None, *, label=None)[source]

Bases: BaseDrive

Drive authoring base for a two-endpoint coupling Hamiltonian.

Subclasses implement hamiltonian() for the coupling physics they accept. The base class imposes no parametric-interaction requirement.

Parameters:
property device_label: None

Return None because a coupling drive has no device target.

property target_label: str | None

Label of the connected coupling, if any.

connect(target)[source]

Attach this line to a coupling without a device-side handshake.

Parameters:

target (Any)

Return type:

None

class quchip.control.drive.ChargeDrive(target=None, *, label=None)[source]

Bases: DeviceDrive

Microwave charge drive on a transmon-like device.

Contributes the standard charge-coupling Hamiltonian

\[H_d(t) = \epsilon(t)\, i(\hat a - \hat a^\dagger)\]

with \(\epsilon(t)\) the in-phase quadrature of the complete delivered classical signal. This is the canonical transmon microwave drive (Koch et al., PRA 76, 042319 (2007); Krantz et al., APR 6, 021318 (2019), Eq. 90).

Examples

>>> from quchip import DuffingTransmon, ChargeDrive
>>> q = DuffingTransmon(freq=5.0, anharmonicity=-0.25, levels=3)
>>> drive = ChargeDrive(target=q)
>>> drive.target_label == q.label
True
Parameters:
hamiltonian(device, signal)[source]

Map a delivered classical signal to target-local quantum physics.

Parameters:
Return type:

Any

physics_notes()[source]

Return human-readable declarations of this drive’s approximations.

Subclasses append their physical coupling details to the shared target line. Aggregated by Chip.physics_notes().

Return type:

list[str]

class quchip.control.drive.PhaseDrive(target=None, *, label=None)[source]

Bases: DeviceDrive

Microwave phase drive coupling to \(\hat a + \hat a^\dagger\).

Same carrier machinery as ChargeDrive but with an in-phase (rather than quadrature) coupling. Useful when modelling phase-noise channels or drives whose physical coupling is already referenced to the field quadrature. See Krantz et al. 2019, Sec. IV.A for the two conventions.

Parameters:
hamiltonian(device, signal)[source]

Map a delivered classical signal to target-local quantum physics.

Parameters:
Return type:

Any

physics_notes()[source]

Return human-readable declarations of this drive’s approximations.

Subclasses append their physical coupling details to the shared target line. Aggregated by Chip.physics_notes().

Return type:

list[str]

class quchip.control.drive.FluxDrive(target=None, *, label=None)[source]

Bases: DeviceDrive

Real-valued flux drive coupling to \(\hat n\).

The delivered signal’s in-phase quadrature modulates the device frequency through its flux-coupling operator (Koch et al. 2007, Sec. II; Krantz et al. 2019, Sec. V.A on flux tunability).

Examples

>>> from quchip import DuffingTransmon, FluxDrive
>>> q = DuffingTransmon(freq=5.0, anharmonicity=-0.25, levels=3)
>>> flux = FluxDrive(target=q)
>>> flux.target_label == q.label
True
Parameters:
hamiltonian(device, signal)[source]

Map a delivered classical signal to target-local quantum physics.

Parameters:
Return type:

Any

physics_notes()[source]

Return human-readable declarations of this drive’s approximations.

Subclasses append their physical coupling details to the shared target line. Aggregated by Chip.physics_notes().

Return type:

list[str]

class quchip.control.drive.ParametricDrive(target=None, *, label=None)[source]

Bases: CouplingDrive

Control line pumping a modulable coupling’s strength δ(t) in GHz.

Targets a coupling (object or label string; labels late-bind via Chip.connect()). The scheduled envelope is the real amplitude A(t): with an explicit carrier the pump is δ(t) = A(t)·cos(2π·freq·t - phase); with freq omitted the pump is carrier-free, δ(t) = A(t) directly. Approximation belongs to the chip’s selected engine strategy, not to the drive.

Accepted couplings implement parametric_interaction(); a static coupling raises TypeError naming the hook.

Parameters:
  • coupling (BaseCoupling | str) – Modulable coupling to pump, given as the coupling object or its label. A string label late-binds to the coupling instance via Chip.connect().

  • label (str | None) – Optional explicit label; otherwise auto-generated from "parametric".

  • target (Any)

Raises:

TypeErrorcoupling does not implement parametric_interaction() (a static coupling), or an unexpected keyword argument is passed.

connect(coupling)[source]

Attach this line after confirming that the coupling is modulable.

Parameters:

coupling (Any)

Return type:

None

hamiltonian(coupling, signal)[source]

Map a delivered classical signal to target-local quantum physics.

Parameters:
Return type:

Any

physics_notes()[source]

Return human-readable declarations of this drive’s approximations.

Subclasses append their physical coupling details to the shared target line. Aggregated by Chip.physics_notes().

Return type:

list[str]