Homework Matlab® 1

advertisement
Homework Matlab® 1
1250
S 14
QOD:
Put sticky note in your MATLAB® textbook for the tables in the "Summary" at the
end of Chapter 2.
1.
In Lab 2, you hooked up the resistor network shown below. Use MATLAB® to
calculate the total resistance. Break up the calculation by defining variables for
resistances of pieces of the circuit as you go.
Use parentheses as needed to get the correct order of calculation. Your answer will
be the line of code you used and the answer it produced.
Problem 2.36 Use resistance reduction and source transformation to find Vx in the
® code
2. of Fig. Use
circuit
P2.36.MATLAB
All resistance
valuesto
arecalculate
in ohms. the total resistance seen
Solution:
by the 10 A source of the
circuit in Prob. 2.36 of the Ulaby and Maharbiz textbook (used with permission of
publisher) shown below:
+ Vx _
4
Figure P2.36: Circuit
for Problem 2.36.
16
16
12
10 A
6
4
16
16
It is convenient to use
the "parallel operator"
denoted by two parallel lines to write
4
+ Vx _
formulas for resistance. For Prob. 2.36,4 we have the following formula for the
10 A
8
12
6
8
equivalent resistance, which you are to compute with MATLAB®:
(16 ||16 + 4) ||12 || 6 || (4 + 16 ||16)
V
_
+ x has higher precedence than addition and
Note: In calculations, the parallel operator
4
10 A values
6
multiplication, meaning 6the parallel
are 8computed before the additions. We
use parentheses to force additions to be done first when necessary.
+ Vx _
10 A
3
4
8
+ Vx _
30 V
+
_
3
4
8
3.
Use MATLAB® to verify that common factors of resistor values may be factored out
in parallel resistance calculations. That is, verify that the following calculation is
valid by calculating the left side and right side and showing they are equal to the
middle value:
(16 ||16 + 4) ||12 || 6 || (4 + 16 ||16)Ω = 2.4 Ω = 2 ⋅(8 || 8 + 2) || 6 || 3 || (2 + 8 || 8)Ω
Note: The parallel calculations are done before multiplying by two, since the parallel
operator has higher precedence than addition or multiplication.
4.
Problem 2.15 of Matlab® for Engineers by Holly Moore. In addition to the problem
as stated, calculate the voltage drop on the wire using the MATLAB® sqrt() function
and the following formula (derived from P = V 2 / R ):
V = PR
5.
Fill in the tables below for Ohm's law. These tables define how engineering prefixes
behave when multiplied or divided. After you have filled in the tables, define
variables in MATLAB® for all the engineering prefixes commonly used by electrical
and computer engineers. For example, define m = 10–3 and n = 10–9. Use your
MATLAB® variables to verify the answers in the gray squares.
v=iR
in V
i
R in Ω
1n 1µ 1m 1
i=v/R
in A
1k
1n
1µ
in 1m
v
1n
1k
A 1k
1M
1n 1µ 1m 1
1k 1M
1n
1µ
1f
1
6.
1M
R in Ω
in 1m
1k
1k
1n
1
1M
1G
V 1k
1M
1
1G
Use MATLAB® to verify the calculation in the solution of Prob 2.5, page 82 of
Ulaby and Maharbiz text:
R
−1
R
R0
−3 −1
= 2.5°C
= 1.01 , α = 4 × 10 °C , and T =
α
R0
Note: T is the temperature where the value of a resistor changes by 1% relative to its
value at 0°C.
Download