Nodal analysis with two voltage sources

circuit analysisdcgroundvoltagevoltage measurement

EDIT: I am not removing the linked question and redoing the question.

How do you formulate an equation on a node with two voltage sources connected in it, regardless if it is a supernode or not?

(You may ignore the statements below this.)


Though this question has been answered here, I still have doubts in mind.

Consider the circuit below. In the linked question above, both voltage sources have the same value for voltage. The circuit below has 30 V and 20 V. Will it still be zero just like the one in the linked question? If not, how should you create the nodal equation for node 1? Usually, if there is only one voltage source connected to the node, and if it is connected to the ground, you just equate V to the value of voltage source. (Let's say below, if there is no 2 kΩ resistor below node 2, V1 = 30 V.)

An additional question as well. What if there are two voltage sources, but the other one is not independent but a VCVS or CCVS? How do you formulate the equation at that certain node with those branches connected?

enter image description here

Best Answer

In general, you don't create an equation for node 1. You take nodes 1, 2 and 3 together as a single node, called a generalized node, aka supernode, for current summing purposes, and create an equation for that. Like this: Let the voltages at nodes N1, N2 and N3 be called \$v_1\$, \$v_2\$ and \$v_3\$, respectively. You can sum the currents out of the supernode: $$ \frac{v_2}{ 2\mathrm{k\Omega}} + \frac{v_3}{ 5\mathrm{k\Omega} }+\frac{v_1}{ 4\mathrm{k\Omega} }= 0 $$ You now have three unknowns and one equation, but you know that \$ v_2 = v_1 - 30 \$ and \$v3 = v1 - 20\$, so you can back-substitute into the previous equation and solve it for \$v_1\$

Dependant sources are handled in the same manner.