Skip to content

Instantly share code, notes, and snippets.

@ntezak
Created December 11, 2012 01:59
Show Gist options
  • Save ntezak/4255134 to your computer and use it in GitHub Desktop.
Save ntezak/4255134 to your computer and use it in GitHub Desktop.
QNET code example
import qnet.circuit_algebra as ca
import sympy
Q = ca.local_space('Q')
a = ca.Destroy(Q)
Delta, kappa = sympy.symbols('Delta, kappa', real = True)
H = Delta * a.dag() * a
L = ca.Matrix(ca.sqrt(Delta) * a)
S = ca.identity_matrix(1)
cavity_model = ca.SLH(S, L, H)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment