Your first simulation¶
How much population does a Gaussian pulse leave in a transmon’s first excited state? Declare a four-level transmon, wire a charge drive, and apply a 20 ns pulse. Frequencies are in GHz and times are in ns.
Declare the chip and drive¶
import numpy as np
from quchip import RWA, ChargeDrive, Chip, DuffingTransmon, Gaussian, QuantumSequence
q = DuffingTransmon(freq=5.0, anharmonicity=-0.25, levels=4, label="q")
chip = Chip([q], frame="rotating", approximation=RWA())
line = ChargeDrive(q, label="xy")
chip.wire(line)
The model uses a rotating frame and the rotating-wave approximation. No loss channels are declared, so this calculation describes coherent evolution.
Schedule and simulate¶
sequence = QuantumSequence(chip)
sequence.schedule(
line,
envelope=Gaussian(duration=20.0, sigmas=3.0, amplitude=0.04),
freq=chip.freq(q),
)
result = sequence.simulate(
tlist=np.linspace(0.0, 30.0, 121),
initial_state=chip.state({q: 0}),
)
print(f"Final excited-state population: {result.population(q, 1)[-1]:.3f}")
Final excited-state population: 0.745
The pulse transfers about 75% of the population into |1⟩. It has not been
calibrated as a π pulse. The higher levels allow population to leak into |2⟩;
read it with result.population(q, 2).
Increasing the model from four to five levels changes the final |1⟩ population by less than one part in a million for this pulse.
Continue with pulses, leakage, and readout to compare short and long pulses on a coupled transmon–resonator model.