# Calculating input impedance of 3 port network

I am trying to derive a expression for calculating the input impedance of a 3 port network to use as direct calculating code and avoid SPICE/simulator solving of the same.

I am able to solve the input impedance of a 2 port system with a load, $$\Z_{load}\$$, connected to port 2. The impedance looking into port 1 would be (by solving basic 2 port theory):

$$Z_{in} = Z_{11} - \frac{Z_{21}Z_{12}}{Z_{22}+Z_{load}}$$

If I have a 3 port network with 2 ports connected to different loads, $$\Z_{load1}\$$ and $$\Z_{load2}\$$, how can I generate an expression for $$\Z_{in}\$$ looking in from port 1 starting from only the Z-matrix, $$\Z_{load1}\$$ and $$\Z_{load2}\$$?

• Can you use LaTex to type in your equation? It looks better. – Niteesh Shanbog Nov 5 '18 at 7:15
• Didn't you think it relevant to actually show the circuit of your 3 port network? – Andy aka Nov 5 '18 at 11:02
• @Andyaka I believe he's referring to the 3-port version of a generic two-port network instead of a specific circuit. – Sven B Nov 5 '18 at 13:47
• @Andyaka Im sorry if my question wasnt too clear, but as Sven mentioned, it is for a generic network – Sum_one Nov 6 '18 at 6:48

The 3-port can be described in 3 equations, using

$$\left(\begin{matrix} V_1 \\ V_2 \\ V_3 \end{matrix}\right) = \left(\begin{matrix} Z_{11} & Z_{12} & Z_{13} \\ Z_{21} & Z_{22} & Z_{23} \\ Z_{31} & Z_{32} & Z_{33} \end{matrix}\right)\left(\begin{matrix} I_1 \\ I_2 \\ I_3\end{matrix}\right)$$

\begin{align} V_1 &= -Z_{L1}\cdot I_1 \\ V_2 &= -Z_{L2}\cdot I_2 \end{align}

This can be inserted into the matrix notation:

$$\left(\begin{matrix} Z_{11} & Z_{12} & Z_{13} \\ Z_{21} & Z_{22} & Z_{23} \\ Z_{31} & Z_{32} & Z_{33} \end{matrix}\right)\left(\begin{matrix} I_1 \\ I_2 \\ I_3\end{matrix}\right) = \left(\begin{matrix} -Z_{L1}\cdot I_1 \\ -Z_{L2}\cdot I_2 \\ V_3 \end{matrix}\right)$$

Which is the same as

$$\left(\begin{matrix} Z_{11} + Z_{L1} & Z_{12} & Z_{13} \\ Z_{21} & Z_{22} + Z_{L2} & Z_{23} \\ Z_{31} & Z_{32} & Z_{33} \end{matrix}\right)\left(\begin{matrix} I_1 \\ I_2 \\ I_3\end{matrix}\right) = \left(\begin{matrix} 0 \\ 0 \\ V_3 \end{matrix}\right)$$

Since we want to solve for $$\Z_{in} = \frac{V_3}{I_3}\$$, we can use Cramer's rule to find

$$I_3 = \frac{\left|\begin{matrix} Z_{11} + Z_{L1} & Z_{12} & 0 \\ Z_{21} & Z_{22} + Z_{L_2} & 0 \\ Z_{31} & Z_{32} & V_3 \end{matrix}\right|}{\left|\begin{matrix} Z_{11} + Z_{L1} & Z_{12} & Z_{13} \\ Z_{21} & Z_{22} + Z_{L2} & Z_{23} \\ Z_{31} & Z_{32} & Z_{33} \end{matrix}\right|}\$$

Or also

$$Z_{in} = \frac{V_3}{I_3} = \frac{\left|\begin{matrix} Z_{11} + Z_{L1} & Z_{12} & Z_{13} \\ Z_{21} & Z_{22} + Z_{L2} & Z_{23} \\ Z_{31} & Z_{32} & Z_{33} \end{matrix}\right|}{\left|\begin{matrix} Z_{11} + Z_{L1} & Z_{12} & 0 \\ Z_{21} & Z_{22} + Z_{L_2} & 0 \\ Z_{31} & Z_{32} & 1 \end{matrix}\right|}$$

• Thank you very much for the very clear derivation of the expression. Which position of the resultant 3x3 matrix generated would be used as the Zin term to be plotted? I tried implementing this expression in Python( taking inverse of the denominator matrix and multipying with numerator array to generate a 3x3 matrix) but could not match the result with simulator output ( sorry but unable to reproduce code due to company restrictions) – Sum_one Nov 6 '18 at 6:53
• Cramer's rule involves calculating determinants, ie. scalars. The result is not a matrix. $|A| = det(A)$. – Sven B Nov 6 '18 at 9:21
• Thank you for the clarification. Really appreciate your help in understanding this complex problem – Sum_one Nov 6 '18 at 23:51