Page 75 -
P. 75
If we know the value of V , R, and R , then Eqs. (3.4) and (3.5) can be repre-
1
s
sented as lines drawn on a plane with ordinate I and abscissa V.
Suppose we are interested in finding the value of the current I and the volt-
age V when R = 100Ω, R = 100Ω, and V = 5 V. To solve this problem graphi-
1
s
cally, we plot each of the L and L functions on the same graph and find their
1
2
point of intersection.
The functions L and L are programmed as follows:
1
2
function I=L1(V)
R1=100;
R=100;
Vs=5;
I=(Vs-V)/R1;
function I=L2(V)
R1=100;
R=100;
Vs=5;
I=V/R;
Because the voltage V is smaller than the source potential, due to losses in the
resistor, a suitable domain for V would be [0, 5]. We now plot the two lines on
the same graph:
fplot('L1',[0,5])
hold on
fplot('L2',[0,5])
hold off
In-Class Exercise
Pb. 3.5 Verify that the two lines L and L intersect at the point: (I = 0.025, V
1
2
= 2.5).
In the above analysis, we had to declare the numerical values of the param-
eters R and R in the definition of each of the two functions. This can, at best,
1
be tedious if you are dealing with more than two function M-files or two
parameters; or worse, can lead to errors if you overlook changing the values
of the parameters in any of the relevant function M-files when you decide to
modify them. To avoid these types of problems, it is good practice to call all
© 2001 by CRC Press LLC