Skip to content

Commit

Permalink
Add leakage penalty to multilevel_transmon example
Browse files Browse the repository at this point in the history
  • Loading branch information
aarontrowbridge committed Dec 19, 2023
1 parent 873f6d8 commit 4badf05
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions docs/src/generated/examples/multilevel_transmon.md
Original file line number Diff line number Diff line change
Expand Up @@ -140,8 +140,11 @@ plot(prob.trajectory, [:a];
As can bee seen in the plot above, although the fidelity is high, the $f$ level of the transmon is highly populated throughout the evolution. This is suboptimal, but we can account for this by penalizing the leakage elements of the unitary, namely those elements of the form $U_{f, i}$ where $i \neq f$. We utilize an $L_1$ penalty on these elements, which is implemented in the [`UnitarySmoothPulseProblem`](@ref) type as the `leakage_penalty` keyword argument.

````@example multilevel_transmon
# get the indices of the leakage subspace of the isomorphic vector representation
# of the unitary
leakage_indices = subspace_leakage_indices(levels)
# set the leakage penalty
R_leakage = 1.0e0
new_prob = UnitarySmoothPulseProblem(
Expand Down

0 comments on commit 4badf05

Please sign in to comment.