📄 impedance.m
字号:
% prob1-2
% plot real & imaginary part of characteristic impedance and alpha/beta
% versus omega for [0,16pi] rad/s
R=0; L=1; G=0.1; C=1;
w = 0:0.4*pi:16*pi;
gamma = size(1:max(size(w)));
for i=1:max(size(w))
gamma(i) = sqrt((R+j*w(i)*L)*(G+j*w(i)*C));
Z(i) = sqrt((R+j*w(i))/(G+j*w(i)*C));
end
%Z = sqrt((R+j*w)/(G+j*w*C));
alpha = real(gamma);
beta = imag(gamma);
figure;
%subplot(1,2,1);
plot(w,real(Z),'-','LineWidth',2);
grid on;
xlabel('\omega(rad/s)');
axis([-3 63 -0.1 1.1]);
title('real part of characteristic impedance');
figure;
%subplot(1,2,2);
plot(w,imag(Z),'-','LineWidth',2);
grid on;
axis([-3 60 -0.005 0.045]);
xlabel('\omega(rad/s)');
title('imaginary part of characteristic impedance');
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -