Media.random(n_ports=1, reciprocal=False, matched=False, symmetric=False, **kwargs)[source]

Complex random network.

Creates a n-port network whose s-matrix is filled with random complex numbers. Optionaly, result can be matched or reciprocal.

  • n_ports (int) – number of ports.
  • reciprocal (bool) – makes s-matrix symmetric ($S_{mn} = S_{nm}$)
  • symmetric (bool) – makes s-matrix diagonal have single value ($S_{mm}=S_{nn}$)
  • matched (bool) – makes diagonals of s-matrix zero
  • **kwargs (passed to Network) – initializer

result – the network

Return type:

Network object