3.6 USE OF MATLAB IN COMPUTER-AIDED CIRCUIT SIMULATION 175
At nodeB:
VB(s)
1 /Cs
+
VB(s)−VA(s)
Ls
−
iL( 0 )
s
−CvC( 0 )= 0
Rearranging these equations, one gets
NodeA:
(
G+
1
Ls
)
VA(s)−
(
1
Ls
)
vB(s)=IS(s)−
iL( 0 )
s
NodeB: −
1
Ls
VA(s)+
(
1
Ls
+Cs
)
VB(s)=CvC( 0 )+
iL( 0 )
s
whereG= 1 /R. The M-file answers are as follows:
function example362
clc
symssGLCISiLvC
% Admittance Matrix
Y = [G+1/L/s− 1/L/s;−1/L/s C*s+1/L/s]
% Current Vector
I=[IS−iL/s; iL/s+C*vC]
% Inverse of Y
inv(Y)
% Node Voltage Solutions
V = factor(inv(Y)*I)
Y=
[ G+1/L/s, -1/L/s]
[ −1/L/s, C*s+1/L/s]
I=
[IS−iL/s]
[ iL/s+C*vC]
ans =
[ (C*s∧2*L+1)/(G*L*s∧2*C+G+C*s), 1/(G*L*s∧2*C+G+C*s)]
[ 1/(G*L*s∧2*C+G+C*s), (G*L*s+1)/(G*L*s∧2*C+G+C*s)]
V=
[ (C*s∧2*L*IS-C*s*L*iL+IS+C*vC)/(G*L*s∧2*C+G+C*s)]
[ (IS+G*L*iL+G*L*s*C*vC+C*vC)/(G*L*s∧2*C+G+C*s)]
EXAMPLE 3.6.3
Abandpassfilter design can be accomplished through the cascade connection shown in Figure
E3.6.3, where the frequencies between the two cutoffs fall in the passband of both filters and
are transmitted through the cascade connection, thereby producing the passband of the resulting
bandpass filter.
ωCHP = ωC 1
High-pass filter
ωCLP = ωC 2 >> ωC 1
Low-pass filter Figure E3.6.3through cascade connection ofBandpass filter
high-pass and low-pass filters.