TwoModeSqueezing

Module: pennylane

class TwoModeSqueezing(r, phi, wires)[source]

Phase space two-mode squeezing.

\[S_2(z) = \exp\left(z^* \a \hat{b} -z \ad \hat{b}^\dagger \right) = \exp\left(r (e^{-i\phi} \a\hat{b} -e^{i\phi} \ad \hat{b}^\dagger \right).\]

where \(z = r e^{i\phi}\).

Details:

  • Number of wires: 2

  • Number of parameters: 2

  • Gradient recipe: \(\frac{d}{dr}f(S_2(r,\phi)) = \frac{1}{2\sinh s} \left[f(S_2(r+s, \phi)) - f(S_2(r-s, \phi))\right]\), where \(s\) is an arbitrary real number (\(0.1\) by default) and \(f\) is an expectation value depending on \(S_2(r,\phi)\).

  • Heisenberg representation:

    \[\begin{split}M = \begin{bmatrix} 1 & 0 & 0 & 0 & 0 \\ 0 & \cosh r & 0 & \sinh r \cos \phi & \sinh r \sin \phi\\ 0 & 0 & \cosh r & \sinh r \sin \phi & -\sinh r \cos \phi\\ 0 & \sinh r \cos \phi & \sinh r \sin \phi & \cosh r & 0\\ 0 & \sinh r \sin \phi & -\sinh r \cos \phi & 0 & \cosh r \end{bmatrix}\end{split}\]
Parameters:
  • r (float) – squeezing amount
  • phi (float) – squeezing phase angle \(\phi\)
  • wires (Sequence[int] or int) – the wire the operation acts on