spheres.spin_circuits.strawberryfields.spinj_xyz_strawberryfields

spheres.spin_circuits.strawberryfields.spinj_xyz_strawberryfields(state, on_modes=[0, 1], XYZ=None)[source]

Returns XYZ expectation values of a spin encoded in two oscillator modes.

Parameters
  • state (strawberryfields.state) –

  • on_modes (list) – Two modes encoding the spin, e.g., [0,1].

  • XYZ (dict) – XYZ operators as real symplectic matrices. Constructed if not provided.

Returns

xyz – XYZ expectation values.

Return type

np.array