前言
微波计算:A 参数计算 S 参数
题目
题目:给定微波网络的A参数矩阵,计算对应的S参数矩阵。
已知微波网络的A参数矩阵为:
A
=
[
A
11
A
12
A
21
A
22
]
A = \begin{bmatrix} A_{11} & A_{12} \\ A_{21} & A_{22} \end{bmatrix}
A=[A11A21A12A22]
其中,A参数与S参数之间的关系由以下公式给出:
S
=
1
det
(
A
)
[
A
s
u
m
r
o
w
1
−
A
s
u
m
r
o
w
2
2
det
(
A
)
2
A
s
u
m
c
o
l
u
m
n
2
−
A
s
u
m
c
o
l
u
m
n
1
]
S = \frac{1}{\det(A)} \begin{bmatrix} A_{sum_{row1}} - A_{sum_{row2}} & 2\det(A) \\ 2 & A_{sum_{column2}} - A_{sum_{column1}} \end{bmatrix}
S=det(A)1[Asumrow1−Asumrow222det(A)Asumcolumn2−Asumcolumn1]
计算S参数矩阵的步骤如下:
-
计算A参数矩阵的行列式:
det ( A ) = A 11 A 22 − A 12 A 21 \det(A) = A_{11}A_{22} - A_{12}A_{21} det(A)=A11A22−A12A21 -
将计算得到的S参数矩阵元素组合成S参数矩阵:
S = [ S 11 S 12 S 21 S 22 ] S = \begin{bmatrix} S_{11} & S_{12} \\ S_{21} & S_{22} \end{bmatrix} S=[S11S21S12S22]
根据以上步骤,可以计算出微波网络的S参数矩阵。
代码
% init
A_1 = sqrt(1/2) * [1, 1i; ...
1i, 1];
A_2 = [1, 1; ...
0, 1];
A_3 = [1, 0; ...
1, 1];
S = [1i, 1; ...
1, -1i];
Gamma_1 = 0.5;
% calc
A_123 = A_1 * A_2 * A_3;
S_1 = a2s(A_123);
Gamma_2 = load_calc(S_1, Gamma_1);
Gamma_3 = load_calc(S, Gamma_2);
11/14
3/11
%%
function S = a2s(A)
S = 1 / sum(A, 'all') * [sum(A(1, :)) - sum(A(2, :)), 2 * det(A);
2 , sum(A(:, 2) - sum(A(:, 1)))];
end
function Gamma_2 = load_calc(S, Gamma)
Gamma_2 = S(1, 1) + S(1, 2) * S(2, 1) * Gamma / (1 - S(2, 2) * Gamma);
end
结果
ans =
0.7857
ans =
0.2727