Converting S-Parameters to Z-Parameters for a Two-Port
Z = Z0(I+S)(I−S)^-1 turns a two-port S-matrix into a Z-matrix. A 50 Ω shunt resistor with S11 = −1/3 and S21 = 2/3 gives Z11 = Z21 = 50 Ω, and a pure series element gives det(I − S) = 0, so it has no Z-matrix.
Engineer’s note: Simulators do this for you now, but when matching an antenna I still convert S11 back to impedance, the real part R and the imaginary part X. That tells you straight away whether the antenna looks capacitive or inductive, and whether to start with a series L or a shunt C.
For practitioners
A VNA gives you S-parameters. Circuit models, many textbook derivations and some simulators work in Z-parameters. This page shows the matrix conversion between them, works it through a shunt resistor where the answer is easy to check, and shows the one case where the conversion has no answer.
The conversion formula and where it comes from
Z-parameters relate port voltages to port currents: V = Z·I_port, where V and I_port are column vectors holding V1, V2 and I1, I2. S-parameters relate the outgoing waves b to the incoming waves a: b = S·a.
When every port has the same real reference impedance Z0, the voltage and current at each port are:
Substitute b = S·a. Then V = √Z0 (I + S)·a and I_port = (I − S)·a / √Z0. Solve the second equation for a and put it into the first:
Here I is the 2×2 identity matrix, not a current. (I + S) and (I − S) commute, so you can write the inverse on either side and get the same result.
The two-port expressions written out
For a 2×2 matrix the inverse is simple enough to expand by hand. Define
Then the four Z-parameters are:
All quantities are complex. If your data comes from a Touchstone file in dB/angle or magnitude/angle format, convert each entry to real and imaginary parts before you put it into these expressions. The S-parameters must also be referenced to the Z0 you use in the formula. For a .s2p file, that value is in the option line.
Two quick structural checks. A reciprocal network (S12 = S21) gives Z12 = Z21. A symmetric network (S11 = S22) gives Z11 = Z22. If your converted matrix breaks a symmetry the original S-matrix had, look for a bookkeeping error.
Worked example: a 50 Ω shunt resistor
Take a resistor R = 50 Ω from the signal line to ground, with ports on both sides referenced to Z0 = 50 Ω. Its S-parameters are:
- S11 = S22 = −Z0/(2R + Z0) = −50/150 = −1/3
- S21 = S12 = 2R/(2R + Z0) = 100/150 = 2/3
Compute the pieces:
- 1 − S11 = 1 − S22 = 4/3
- 1 + S11 = 2/3
- S12·S21 = 4/9
The determinant:
Δ = (4/3)(4/3) − 4/9 = 16/9 − 4/9 = 12/9 = 4/3
Numerator of Z11: (2/3)(4/3) + 4/9 = 8/9 + 4/9 = 12/9 = 4/3. So
Z11 = 50 × (4/3)/(4/3) = 50 Ω
Numerator of Z21: 2 × 2/3 = 4/3. So
Z21 = 50 × (4/3)/(4/3) = 50 Ω
The network is symmetric and reciprocal, so Z22 = Z11 = 50 Ω and Z12 = Z21 = 50 Ω.
This matches the circuit. With port 2 open, any current pushed into port 1 can only flow through R to ground. That gives V1 = I1·R, and because both ports sit on the same node, V2 = I1·R as well. For a shunt R, every entry of the Z-matrix is R. Here that is 50 Ω.
When the Z-matrix does not exist
The conversion needs (I − S)^-1, and that inverse does not exist when Δ = det(I − S) = 0. The standard case is a pure series element.
Take a series impedance Z = 50 Ω between port 1 and port 2, with Z0 = 50 Ω:
- S11 = S22 = Z/(Z + 2Z0) = 50/150 = 1/3
- S21 = S12 = 2Z0/(Z + 2Z0) = 100/150 = 2/3
So 1 − S11 = 2/3 = S21, and
I − S = [2/3, −2/3; −2/3, 2/3]
det(I − S) = (2/3)(2/3) − (2/3)(2/3) = 0
This is not specific to 50 Ω. For any series element, 1 − S11 = 2Z0/(Z + 2Z0) = S21, so the determinant always cancels to zero. The physics explains why. Z11 is defined with port 2 open. With an open at port 2, a series element has no path to ground, so no current flows for any finite V1, and the open-circuit impedance is infinite.
The fix is to use the dual representation. Y-parameters are defined with the other port shorted, and they exist for a series element:
For a series impedance Z, this gives Y11 = Y22 = 1/Z and Y12 = Y21 = −1/Z. The shunt element is the dual case: it has a Z-matrix but no Y-matrix.
Practical checks on converted data
- Check the determinant before you trust the result. If |det(I − S)| gets small across a band, the Z-values there are dominated by measurement noise. A series-dominated structure such as a series inductor, a coupling capacitor or a long thru is the usual cause.
- Check reciprocity and symmetry. Passive, reciprocal parts should come out with Z12 = Z21, within measurement noise.
- Check with a known part. A shunt resistor is a good test case for a conversion script, because every Z entry should equal R at all frequencies.
- Keep Z0 consistent. Using 50 where the file says 75, or forgetting that the file was renormalized, scales every entry of Z and changes the shape of the result.
In plain words · for students and beginners
S-to-Z conversion in plain words
An everyday picture
Think of a network of water pipes with two outlets. S-parameters are like sending a wave of water down a hose and watching how much bounces back and how much comes out the far end. Z-parameters are a different test. You cap one outlet, push a steady flow into the other, and read the pressure at both outlets. Here "pressure" stands for voltage and "flow" stands for current.
Both tests describe the same pipes, so you can calculate one from the other. The analogy breaks down at RF because you can't really build a perfect cap (an "open circuit") at high frequency. That is why instruments measure waves (S) and we convert to Z with math afterwards.
The same example, step by step
- The circuit is a 50 Ω resistor from the signal line to ground. Port 2 is left open, which means nothing is connected there.
- Push a current of 1 A into port 1.
- The current has only one path, through the resistor to ground. Voltage = current × resistance = 1 A × 50 Ω = 50 V. So V1 = 50 V.
- Port 2 is on the same wire as port 1, so V2 = 50 V too.
- Z11 = V1 / I1 = 50 V / 1 A = 50 Ω. Z21 = V2 / I1 = 50 V / 1 A = 50 Ω.
Now check this with the formula. The S-parameters are S11 = −1/3 and S21 = 2/3. The bottom number Δ = (4/3)(4/3) − 4/9 = 4/3. The top numbers are also 4/3, so both Z11 and Z21 come out to 50 × 1 = 50 Ω. The circuit and the formula agree.
Why a series part has no answer
Now put the resistor in series, inside the line, between the two ports. Cap port 2 and try to push current into port 1. The current has nowhere to go, because there is no path to ground. You would need infinite voltage to force any current in, so "voltage divided by current" has no finite value.
The math shows the same thing. The matrix (I − S) has a determinant of zero, and you can't divide by zero. In this case, use Y-parameters instead. They short the other port instead of leaving it open, so the current has a path.
Mistakes beginners make
- Confusing the two I's. In Z = Z0(I + S)(I − S)^-1, I is the identity matrix (1s on the diagonal, 0s elsewhere). It is not a current.
- Converting entry by entry. Z11 is not a function of S11 alone. Every Z entry depends on all four S entries.
- Using dB values directly. S-parameters in a file are often in dB and degrees. Turn them into complex numbers (real plus imaginary) first.
- Using the wrong Z0. The Z0 in the formula must match the reference impedance of the data, usually 50 Ω.
Remember
- Z = Z0(I + S)(I − S)^-1 works when both ports use the same real Z0.
- A 50 Ω shunt resistor converts to a Z-matrix with every entry equal to 50 Ω.
- If det(I − S) = 0, as it is for any series element, no Z-matrix exists. Use Y-parameters instead.
Related pages on RF View
Frequently asked questions
What is the formula to convert S-parameters to Z-parameters?
When every port has the same real reference impedance Z0, Z = Z0(I + S)(I − S)^-1, where I is the identity matrix. For a two-port, Z11 = Z0[(1 + S11)(1 − S22) + S12·S21]/Δ and Z21 = Z0·2S21/Δ, with Δ = (1 − S11)(1 − S22) − S12·S21.
Why does my S to Z conversion give infinite or undefined values?
The conversion needs the inverse of (I − S), and it fails when det(I − S) = 0. A pure series element always gives this result, because 1 − S11 = S21. Its open-circuit impedances are infinite, so convert it to Y-parameters.
What are the Z-parameters of a shunt resistor?
For a shunt resistor R, all four Z-parameters equal R. A 50 Ω shunt resistor in a 50 Ω system has S11 = −1/3 and S21 = 2/3, and the conversion gives Z11 = Z21 = 50 Ω.
Does the order of (I + S) and (I − S)^-1 matter?
No. (I + S) and (I − S) are both polynomials in S, so they commute, and (I + S)(I − S)^-1 equals (I − S)^-1(I + S). The order does matter if you mix it with other matrices or use different reference impedances at different ports.