From S-parameters to H-parameters
In matrix form, the formula is
H=([2k1100−2Z2k21]S+[2k11002Z2k21])([−2Z1k11002k21]S+[2Z1k11002k21])−1
While for each element, we obtain
H11H12H21H22=S22−S11−S11S22+S12S21+1Z1(S11+S22+S11S22−S12S21+1)=k1(S22−S11−S11S22+S12S21+1)2S12k2=−Z2k2(S22−S11−S11S22+S12S21+1)2S21Z1k1=−Z2(S22−S11−S11S22+S12S21+1)S11+S22−S11S22+S12S21−1
The formulas are obtained with the methods explained here.
The MATLAB implementation can be found in circuitconversions on Gitlab.
Definitions
[B1B2]=S[A1A2] | [V1I2]=H[I1V2] |
The incident and reflected waves are defined as
A1A2=k1(V1+I1Z1)B1=k2(V2+I2Z2)B2=k1(V1−I1Z1)=k2(V2−I2Z2)
with Z0,i the reference impedance for port i and ki defined as
ki=2ℜ(Z0,i)1ki=α2∣Z0,i∣ℜ(Z0,i)
depending on whether you are using power- or pseudowaves.