thewalrus.fock_gradients.displacement¶
-
fock_gradients.
displacement
(r, phi, cutoff, dtype=<class 'numpy.complex128'>)¶ Calculates the matrix elements of the displacement gate using a recurrence relation.
- Parameters
r (float) – displacement magnitude
phi (float) – displacement angle
cutoff (int) – Fock ladder cutoff
dtype (data type) – Specifies the data type used for the calculation
- Returns
matrix representing the displacement operation.
- Return type
array[complex]
code/api/thewalrus.fock_gradients.displacement
Download Python script
Download Notebook
View on GitHub
Downloads