Professional Documents
Culture Documents
1
Agenda
1. Recap for class 1
Chapter 5
• Linearity and superposition
Chapter 3
2. Nodal analysis
3. Mesh analysis
4. Systems of equations
2
Class 1 refresher : terminology
• Paths
• Branches
• Nodes
• Passive elements
• Sources
• Terminals
vN(t)
v(t) = v1(t) + v2(t) + ... vN(t)
v3(t)
v(t)
v2(t)
v1(t)
–5+2+3=0
R1 R2 RN
12
Combining series and parallel resistors
Add serial voltage sources (KVL) Add parallel current sources (KCL)
Add serial resistances as V = I R Adding parallel resistors as I = V / R
RAB = 5kΩ
13
Agenda
1. Recap for class 1
Chapter 5
• Linearity and superposition
Chapter 3
2. Nodal analysis
3. Mesh analysis
4. Systems of equations
14
Linearity requires additivity and scaling
Additivity: Multiple added
signals pass through the system
without interacting:
f (v1 + v2) = f (v1) + f (v2)
Variables may change, but the linear equations stay the same, allowing:
Combining components to simplify circuits (last week)
Simpler circuit analysis (using linearity directly, and superposition, part 1)
Adding currents in loop analysis (part 3) and row reduction (part 4) 16
Linearity as an analysis technique
Linearity principle allows
simple solutions 1k 1k
for some circuits 8V 1k 1k
Let’s define
Vout = V2 = 1V
Vout = k V0
V0 is now unknown
Important: If we define the output, arbitrarily as 1V, it is unlikely that
V0 = 8V so this is now a variable 17
Linearity as an analysis technique
Using Ohm’s Law, KCL, KVL
If V2 = 1V
1k 1k
• I2 = 8V 1k 1k
• V1 =
• I1 =
• I0 =
• V0 = A) Vout = 1.0V
B) Vout = 1.3V
• Vout / V0 = C) Vout = 1.6V
• Vout when V0 = 8 V D) Don’t know 18
Linearity as an analysis technique
Using Ohm’s Law, KCL, KVL
If V2 = 1V
1k 1k
• I2 = 1 mA 8V 1k 1k
• V1 = 2 V
• I1 = 2 mA
• I0 = 3 mA
• V0 = 2 + 3x1 = 5V A) Vout = 1.0V
B) Vout = 1.3V
• Vout / V0 = 1/5 C) Vout = 1.6V
• Vout when V0 = 8 V: 8/5 V D) Don’t know 19
Superposition
The overall output caused by two or more inputs is the sum of the
responses that would have been caused by each source individually
f (v1 + v2) = f (v1) + f (v2)
A) Completed
B) Don’t know what to do
1) Redraw the circuit with output V ’0 for the condition where the
voltage source is set to zero
2) Redraw the circuit again for output V ’’0 when the current s
value is zero
Superposition : Example
V ’0 : No voltage source
replace with short circuit
V ’’0 : No current source
replace with open circuit
By superposition : V 0 = V ’0 + V ’’0
Superposition : Example
V 0 = V ’0 + V ’’0
V 0 = V ’0 + V ’’0 = 4 + 2 = 6V
5ECA0 Circuits (ch3): class 2.2 Nodal analysis
27
Agenda
1. Review of class 1
Chapter 3
2. Nodal analysis
• Node voltages as variables
• Sizing the analysis: Number of KCL equations
• Independent and controlled sources
• Supernodes
3. Mesh or loop analysis
4. Systems of equations
28
Many node circuits
29
Referencing
Tip: Number your equations so that you can check your steps later,
and keep the same numbering for identical equations
1
v1 (1/R1+1/R2) – v2 (1/R2) = iA 1
r1
2
v1 (1/R2) + v2 (1/R3 –1/R2) = – iB r
1
v1 (G1+G2) – v2 (G2) = iA 1
r1
2
v1 (G2) + v2 (G3 – G2) = – iB r
37
Independent current sources
(G1+G2) v1 – G2v2 = iA
G2
– (G2) v1 + (G2+G3) v2 = – iB
G1 G3
• N – 1 unknown voltages v1 & v2
• N – 1 linear, independent
• 1 unique solution 1
V1 = 12V 1
0
V3 = – 6V 3
ground
V3 = – 6V 3
V2 –V1 V2 – 0 V2 – V3 2
+ + =0
12k 6k 12k
Substituting and rearranging
0
ground
2 ⇒ V2 = 1.5 V 40
Controlled sources
Controlled source requires an additional constraint equation to describe
dependency in the equations
We would like to know the current i0
KCL@v1
KCL@v2
Determine i0
KCL equations
i0 =v2 /R3
Constraint equation
42
Controlled sources
Nodal analysis
i0 =v2 /R3
Constraint
v1 + 2 v2 = 0 1
– v1 + 3 v2 = 12 2
⇒ v2 = 12/5 V
v1 = – 2 v2 1
= – 24/5 V
i0 = v2 / R3 = 12/5/3k = 4/5 mA
Supernodes
46
Supernodes
KCL@V1
V1–V3 + V1 – iV = 0
6k 12k
KCL@ V2
iV iV
+ V2 + V2 – V3 + iV =0
6k 12k
Adding the equations
47
Supernodes
Now consider the surface with
both nodes KCL@ V1 & V2
All currents in are negative
All currents out are positive
This is the sum of the two KCL
equations, and cancel out the
unknown current in the source
48
Supernodes
Rearranging KCL@ V1 & V2
3V1 + 3V2 – 3V3 = 0 1
Voltage source @ V3
2
1 1 V3 = 6 2
Row reduction: 1 + 2 x3 + 3 4
4V1 = 18
⇒ I0 = V1/12k = 3/8 mA
Nodal analysis : A recipe
• Scope
• N-1 equations for N nodes for a unique solution
• Define reference node and assign voltage variables to the rest
• Constraints
• Identify constraint equation for sources : these are node equations
• Identify constraints for dependent sources
• KCL
• Supernodes should be solve for the surface rather than one node
• Apply KCL for remaining nodes – choose nodes to include all elements
• Solve
• Rearrange to create N – 1 nodal equations
• Substitute (up to 3 nodes) or use linear algebra (more than 3 nodes)
50
5ECA0 Circuits
51
5ECA0 Circuits (ch 3) : class 2.3 Loop analysis
52
Agenda
1. Review of class 1
Chapter 3
2. Nodal analysis
3. Loop analysis
• Kirchoff’s voltage law for loops with voltage sources
• Current sources in loop analysis
• Branch currents and dependant sources
• Identifying loops
• Worked example
4. Systems of equations
53
Loop analysis : KVL refresher ΣV = 0
V12
2
• KVL : Voltage differences around
1
the loop sum to zero
• Electrical voltage potential
+ iC + V23 dropped across resistors
– –
V41 • Using clockwise direction for loop
4 currents
3
V34
58
KVL for loops with independent voltage sources
1) Loop currents defined as IA and IB
Using letters to distinguish from
branch currents I1 I2
A B
I1 I2
A B
2) Branch currents I2 I0
3) KVL
I1 = IA KVL @ IA : 6 IA + 6 (IA– IB) – 12 =0 1
I0 = I A – IB
4) Next solve system of equations 1 & 60
2
Analysis with independent voltage sources
4) Solving for loop currents IA and IB
a) Rearranging
2 IA – IB = 2 1 I1 I2
– 6 I A + 9 IB = – 3 2
A B
I2 I0
3) KCL
KCL @ IA : 6 IA + 6 (IA– IB) – 12 =0 1
61
Analysis with independent voltage sources
4) Solving for loop currents IA and IB
a) Rearranging
2 IA – I B = 2 1 I1 I2
– 6 I A + 9 IB = – 3 2
A B
c) Add ( 1 x3) + 2 3
6 IB =3 3
IB = 6/3 = 0.5 mA 62
Analysis with independent voltage sources
4) Solving for loop currents IA and IB
a) Rearranging
2 IA – IB = 2 1 I1 I2
– 6 I A + 9 IB = – 3 2
A B
1
IA = 2
Need to identify the branch that controls the source 2Vx voltage source
and write down the constraint equation
67
Loop analysis with dependent sources
Warning: If neglecting the
k = 103 from our equations,
remember that the currents
are in units mA (m = 10–3) IA
IB
Loop analysis uses currents
as variables, so need the
equation for controlled
voltage sources Use a constraint equation do define
unknown voltages in terms of currents
Simply maths by having only
one loop current for constraint Vx = 4 IA 68
Loop analysis with dependent sources
For node defined as unique
meeting of elements and
branch defined by elements
B = 5; N = 4; 4–3+1 = 2 loops IA
IB
No current sources so solve
both loops with KVL
KVL for loop IA
– 2Vx + 2 (IA+IB) + 4IA = 0 1
1
– 2Vx + 2 (IA+IB) + 4IA = 0
– 2Vx + 2 (IA+IB) – 3 + 6 IB = 0 2
IA
IB
Constraint equations (from branch)
Vx = 4 IA 3
1
– 2Vx + 2 (IA+IB) + 4IA = 0
– 2Vx + 2 (IA+IB) – 3 + 6 IB = 0 2
IA
IB
Substitute Vx = 4 IA 3 and reorder
– 2 IA + 2 IB = 0 4
– 6 IA + 8 IB = 3 5
71
Loop analysis with dependent sources
Loop equations
1
– 2Vx + 2 (IA+IB) + 4IA = 0
– 2Vx + 2 (IA+IB) – 3 + 6 IB = 0 2
IA
IB
Substitute Vx = 4 IA 3 and reorder
– 2 IA + 2 IB = 0 4
– 6 IA + 8 IB = 3 5 ⇒ IB = 1.5 mA
Back-substituting 6 into 4
Reduce: 4 x3 – 5 6
– 2 IB = – 3 6 ⇒ IA = IB = 1.5 mA 72
Loop selection
Need sufficient loops to
capture all currents in all
branches
Number of loops
required is the number
mA of branches B minus the
number of nodes +1
mA
L = B – N + 1 = 4.
Current sources define
We want to determine voltage V0. a loop current
73
Loop selection: First include current sources
Current sources (mA)
B IA = 2 1
A D
mA
Note that it makes no
C mA sense to include the
current sources for
other equations now
Also note that currents are in units mA and resistances in units kOhms 74
Loop selection: First include current sources
Current sources (mA)
B IA = 2 1
A D
IC = ? 2
mA
Note that it makes no
C mA sense to include the
current sources for
other equations now
Also note that currents are in units mA and resistances in units kOhms 75
Creating loop equation with KVL
Solving for loop D.
B Note we need to
include all the other
A D
loop currents that
flow through a branch
C
Then simplify
B
A: 2IB – IC +2Vx = 0
B: 2IB – IC – 2Vx = 0
C: IB + IC =0
A D
D: 2IB – 2Vx = 0
E: Don’t know
C
A D
Rearrange
C
2IB – IC = 2Vx 4
IA = 2 1
+ IC =–2 2
2IB – IC – 2Vx = 0 3
– IA + IC +2ID – 2Vx =–4 4
IA – IC – ID – Vx = 0 5
82
Agenda
1. Class 1 review
2. Nodal analysis
3. Loop analysis
4. Solving systems of equations
• Representing systems of equations in a scalable way
• Row reduction for two equations
• Row reduction for many equations
• Matlab scripts for checking your algebra
83
Describing linear systems
aV1 + bV2 = c 1
dV1 + eV2 = f 2
aV1 + bV2 = c
dV1 + eV2 = f
Simultaneous equations
A system of linear equations
for two variables with one
unique solution
85
Describing systems of linear equations
aV1 + bV2 = c a b V1 c
dV1 + eV2 = f d e V2 = f
86
Visualising systems of linear equations
aV1 + bV2 = c a b V1 c a b c 1
dV1 + eV2 = f d e V2 = f d e f 2
We will use the augmented matrix form in this class to allow us to perform
algebra with many equations in a more readable way 87
Solving systems of equations
aV1 + bV2 = c a b V1 c a b c 1
dV1 + eV2 = f d e V2 = f d e f 2
Solutions expressed as equations for V1 and V2 with one term per line
a b c 1
1) Write down equations
d e f 2
89
Solving two equations with row reduction
Method: Scale one row so that the same coefficient appears in one column
a b c 1
1) Starting equations
d e f 2
90
Solving two equations with row reduction
Method: Add two rows to replace the unwanted element d with 0
a b c 1
1) Starting equations
d e f
2) Scale row 2 by – a/d –da/d –ea/d –fa/d
–a –ea/d –fa/d 2 x a/d
3) Add rows x a/d + 1
2 '
to create a new row 3 0 b–ea/d c –fa/d 3 +
without element d
91
Solving two equations with row reduction
Method: Scale one row then add two rows to remove an element from row
a b c 1
Updated equations
0 b–ea/d c–fa/d 3
Note that we can only use two out of these three equations now because
they are no longer all unique. Discard equation 2
Column two is V2 so V2 = c–fa/d
b–ea/d
V1 deduced by back-substitution – more later 92
Solved for two nodes ...
For many nodes, we need to think carefully about which rows to reduce
94
Circuit analysis with many nodes
We are going to
calculate V0
How many nodes?
How many
equations?
We will focus now
on the steps rather
than the detail of
the maths
95
Circuit analysis
v1
For nodal analysis
we calculate the
nodal voltages
Any supernodes?
What are the v0 v2 v3
constraint
equations
96
v1
Vx = v2 – v3
1) Write down all the equations required to uniquely describe the circuit 97
Example with nodal analysis
-1.0 v2 + v3 = –6
0 0 -1.0 +1.0 –6 3
0 0 -1 +1 –6 3
+1 0 -3 +2 0 4
0 0 -1 +1 –6 3
+1 0 -3 +2 0 4
0 3 -3.5 -1 6 3 x 1 + 2 5
We have three rows with elements in column 1, but this needs to be one!
First step – remove column one value using rows 1 & 2
Discard row 2 afterwards as we can only use two of these equations now
and row 2 has the most elements 102
Example with nodal analysis
–0.5 1.5 -2.0 0 2 1
0 0 -1 1 –6 3
1 0 -3 2 0 4
0 3 -3.5 -1 6 5
0 3 -7 2 4 2 x 1 + 4 6
Next step – remove another column one value using rows 1 & 4
Discard row 4 afterwards – why column 4?
103
Example with nodal analysis
–0.5 1.5 -2.0 0 2 1
0 0 -1 1 –6 3
1 0 -3 2 0 4
0 3 -3.5 -1 6 5
0 3 -7 2 4 6
0 0 -1 1 –6 3
1 0 -3 2 0 4
0 3 -3.5 -1 6 5
0 3 -7 2 4 6
0 0 -3.5 3 -2 6 - 5 7
0 0 -1 1 –6 3
1 0 -3 2 0 4
0 3 -3.5 -1 6 5
0 3 -7 2 4 6
0 0 -3.5 3 -2 7
0 0 -1 1 –6 3
1 0 -3 2 0 4
0 3 -3.5 -1 6 5
0 3 -7 2 4 6
0 0 -3.5 3 -2 7
0 0 -1 1 –6 3
1 0 -3 2 0 4
0 3 -3.5 -1 6 5
0 3 -7 2 4 6
0 0 -3.5 3 -2 7
0 0 0 +0.5 -19 8
0 3 -7 2 4 6
0 0 -1 1 –6 3
0 0 0 0.5 -19 8
v3 = – ( 19 / 0.5 ) = – 38 V
v2 = – (– 6 – 1 (– 38) ) = – 32 V
v1 = 1/3 ( 4 + 7 (– 32) – 2 (– 38) ) = – 48 V
v0 = – 2 ( 2 – 1.5(– 48) +2 (– 32) ) = – 20 V
111
Row reduction: A recipe