RF Wave Toolbox
09 Aug 2002
07 Mar 2008)
Transmission lines and antennas analysis and design.
% STUB Provides VSWR, reflection coefficient and input impedance
% for a terminated transmission line with a shunt stub at
% the input terminals.
% [VSWR, RHO, ZIN] = STUB(ZL,ZO,ZD,L,LT,ST,BW)
% ZL, ZO and ZD are the load, characteristic and desired
% impedances, respectively. L is the line length, LT is the
% stub length whereas BW is the bandwidth. Values of L and
% LT must be normalized in terms of wavelength and BW
% should be given in percentage.
% ST=10 means short-circuit stub near the generator;
% ST=11 means open-circuit stub near the generator;
% ST=20 means short-circuit stub near the load;
% ST=21 means open-circuit stub near the load.
% RFWave - The Radio Frequency Wave Toolbox
% Versions: 1.0 22-May-1997, 1.1 18-Aug-1999,
% 1.2 16-Jul-2002
% Developed by A. C. de C. Lima
% E-mail: email@example.com
% Electrical Engineering Department
% Federal University of Bahia (UFBA)
function [vswr, rho, zin] = stub(zl,zo,zd,l,lt,st,bw)
if nargin < 7
if st == 11 | st == 21
if st == 11 | st == 10
elseif st == 21 | st == 20
error('ST must be 10, 11, 20 or 21.');