mm.math.random_symplectic¶
- math.random_symplectic(max_r=1.0)¶
A random symplectic matrix in
Sp(2*num_modes)
.Squeezing is sampled uniformly from 0.0 to
max_r
(1.0 by default).- Return type:
ndarray
[Tuple
[int
,...
],Union
[TypeVar
(R
,float16
,float32
,float64
),TypeVar
(C
,complex64
,complex128
),TypeVar
(Z
,int16
,int32
,int64
),TypeVar
(N
,uint16
,uint32
,uint64
)]]
code/api/mrmustard.math.random_symplectic
Download Python script
Download Notebook
View on GitHub