sf.physics.gaussian.mz_symplectic¶
- mrmustard.physics.gaussian.mz_symplectic(phi_a, phi_b, internal=False)[source]¶
Symplectic matrix of a Mach-Zehnder gate.
It supports two conventions:
- if
internal=True, both phases act inside the interferometer: phi_aon the upper arm,phi_bon the lower arm;
- if
- if internal = False (default), both phases act on the upper arm:
phi_abefore the first BS,phi_bafter the first BS.
- Parameters:
phi_a (float) – first phase
phi_b (float) – second phase
internal (bool) – whether phases are in the internal arms (default is False)
- Returns:
symplectic (orthogonal) matrix of a Mach-Zehnder interferometer
- Return type:
Matrix
code/api/mrmustard.physics.gaussian.mz_symplectic
Download Python script
Download Notebook
View on GitHub