edges_cal.reflection_coefficient.SMatrix

class edges_cal.reflection_coefficient.SMatrix(s)[source]

A scattering matrix for a two-port network.

This class eases some of the computations performed with S-parameters. Most of the methods are based on https://en.wikipedia.org/wiki/Scattering_parameters.

See also https://en.wikipedia.org/wiki/Two-port_network#Interrelation_of_parameters

Methods

__init__(s)

Method generated by attrs for class SMatrix.

as_transfer_matrix()

Return a transfer matrix from the SMatrix.

cascade_with(other)

Return a new TwoPortNetwork from the conjunction of two two-port networks.

from_calkit_and_vna(calkit, standards)

Generate an SMatrix from a Calkit definition, and standards measurements.

from_sparams(s11, s12[, s21, s22])

Create a SMatrix from S-parameters.

from_transfer_matrix(t)

Create an SMatrix from a transfer matrix.

from_transmission_line(line, length[, …])

Generate a new SMatrix from a given transmission line object.

is_lossless()

Whether the S-matrix describes a lossless network.

is_reciprocal()

Whether the S-matrix describes a reciprocal network.

voltage_standing_wave_ratio_in()

The Voltage Standing Wave Ratio (VSWR) of the network input.

voltage_standing_wave_ratio_out()

The Voltage Standing Wave Ratio (VSWR) of the network output.

Attributes

complex_linear_gain

The complex linear gain of the network, i.e. S12.

determinant

The determinant of the SMatrix.

input_return_loss

The loss, 1/|S11| in decibels.

insertion_loss

The insertion loss of the network.

nfreq

The number of frequencies in the S-matrix (the last axis).

output_return_loss

The output loss, 1/|S22|, in decibels.

reflection_coefficient_in

The reflection coefficient of the network input, S11.

reflection_coefficient_out

The reflection coefficient of the network output, S22.

reverse_gain

The reverse gain, S|12|, in decibels.

reverse_isolation

The reverse isolation, 1/|S12|, in decibels.

s11

The S11 coefficient of the network.

s12

The S12 coefficient of the network.

s21

The S21 coefficient of the network.

s22

The S22 coefficient of the network.

scalar_linear_gain

The abs value of the linear gain of the network, |S21|.

scalar_logarithmic_gain

The scalar gain, |S21|, in decibels.

s