找回密碼
 立即注冊(cè)

QQ登錄

只需一步,快速開始

搜索
查看: 2975|回復(fù): 0
打印 上一主題 下一主題
收起左側(cè)

微波課程軟件實(shí)驗(yàn)Ⅰ負(fù)載為純電感

[復(fù)制鏈接]
跳轉(zhuǎn)到指定樓層
樓主
ID:80436 發(fā)表于 2015-5-19 20:36 | 只看該作者 回帖獎(jiǎng)勵(lì) |倒序?yàn)g覽 |閱讀模式
      微波仿真實(shí)驗(yàn)
負(fù)載為純電感


%% Transmission line settings ′«êäÏßéèÖÃ
Vp = 3e8;     %Phase velocity of the transmission line ′«êäÏßÏàËù
Z0 = 50;       %Characteristic impedance of the line ′«êäÏßìØÕ÷×è¿1
Length = 3;        %Length of the line (3m) Ïß3¤Îa3Ã×
T = 50e-9;    %Simulation time, starting from 0, ending at T
  
%% Finite Difference Settings
dt = 0.1e-9;         %Time step 2½½ø
N = round(T/dt);     %Total number of time steps
time = [1:N]*dt;     %Array of discrete time points
M = round(Length/Vp/dt);  %Number of time steps taken by the signal to  
                     %propagate through the entire transmission line

%% Source SettingsDÅoÅÔ′éèÖÃ
Rs = 50;              %Source output resistance
Vs = zeros(N,1);
%%% Step function, step change at time t0
t0 = 5e-9; n0 = round(t0/dt); Vs(n0:N)=1.0;
  
%% Load Settings ¸oÔØéèÖà     
L=2e-7;    %Load impedance
  
%% Time-domain Updating
Vi = zeros(N,1);   %Initialization of Vi
Vr = zeros(N,1);   %Initialization of Vr
for n = 1:M
      Vi(n) = Vs(n)/(1+Rs/Z0);
      Vr(n) = 0;
end
Vi(M+1) = (Vs(M+1)-Vr(1)*(1-Rs/Z0))/(1+Rs/Z0);
Vr(M+1) = ((L*Vi(1)+L*Vr(M))/(dt*Z0)-(Vi(1)+Vr(1))/2)*2*dt*Z0/(2*L+dt*Z0);
for n = M+2:N
      Vi(n) = (Vs(n)-Vr(n-M)*(1-Rs/Z0))/(1+Rs/Z0);
      Vr(n) = ((L*Vi(N-M)-L*Vi(N-M-1)+L*Vr(N-1))/(dt*Z0)-(Vi(N-M)+Vi(N-M-1)+Vr(N-1))/2)*2*dt*Z0/(2*L+dt*Z0);
end

%c′«êäÏßéÏx′|μÄμçÑ1
x = 0.5; nx = round(x/Vp/dt);
Vx = [zeros(nx,1);Vi(1:N-nx)] + [zeros(M-nx,1);Vr(1:N-M+nx)];


plot(time*1e9, Vx); hold on; xlabel('Time(ns)'); ylabel('V(x=1)');
title('′«êäÏßéÏx=0.5′|μÄμçÑ12¨DÎ');


   




分享到:  QQ好友和群QQ好友和群 QQ空間QQ空間 騰訊微博騰訊微博 騰訊朋友騰訊朋友
收藏收藏 分享淘帖 頂 踩
回復(fù)

使用道具 舉報(bào)

本版積分規(guī)則

手機(jī)版|小黑屋|51黑電子論壇 |51黑電子論壇6群 QQ 管理員QQ:125739409;技術(shù)交流QQ群281945664

Powered by 單片機(jī)教程網(wǎng)

快速回復(fù) 返回頂部 返回列表