1. Home
  2. Explore
  3. Engineering
  4. Basics of Mesh Analysis

Study methods

Flashcards
Quiz
Fill in the blanks
Written test
Lesson
Notes
Podcast
Content

Basics of Mesh Analysis

Transcript

Now that you’re all experts in nodal analysis,  let’s become experts in mesh analysis, also called   loop analysis. To start, we need to know what a  loop and a mesh is.. So in this circuit, there   are 4 meshes. But this is a loop. Can you see  the difference? A loop, can have a mesh inside,   where as a mesh is a loop without any other loops  inside. So these are some loops. You know those   dolls you can stack on top of each other, the  nesting dolls? You can think of a mesh as the

smallest of the set, the very last one. The others  are all loops because they can have meshes inside.  First, I will cover the basics of mesh analysis,  and then we will do a bunch of examples to really   understand how it works. To begin our analysis,  we first have to define mesh currents. You’re   used to currents being in circuit elements, but a  mesh current is an assumed current flowing in our whole mesh. So here, we have four mesh currents.  The directions you pick for them, so clockwise or   counter-clockwise, is completely up to you,  you get the same answer regardless of what   you pick. If you end up with a negative value,  then you know it’s opposite to your assumption,   but the magnitude of that value is correct. The next step is to write a KVL equation for   each mesh. Remember from the Kirchoff’s voltage  law video that all the voltages added together

in a loop or a mesh must equal zero. Let’s focus  on this mesh and write a KVL. Notice how we don’t   have any positives or negatives labeled on our  resistors. That’s because we always assume we   are entering the positive side of the resistor,  so it will always be positive. So following the   direction of our mesh current, we have V1 plus V2  Plus V3 is equal to 0. Now comes the interesting   part. We want to use ohms law to write each  of these voltages with respect to our mesh

current and the resistor value. Voltage is equal  to the current times the resistance. V1 is easy,   it’s just R1 times I3. But what about V2? We have  two mesh currents in the same branch, I1 and I3.   But keep in mind, we are writing our KVL for this  mesh, so the one with I3. That means I3 is the   boss, in other words, I3 will always be positive  for this mesh. Since I3 is going left to right,

while I1 is going right to left, it’s opposing I3.  So it’s going to get a negative sign. Remember,   I3 is the boss, so I3 takes precedence over the  other shared mesh current. So we have R2 times I3   minus I1. Let’s look at V3. Here, we see that both  I3 and I4 are going down and is not opposing I3,   so I4 will get a positive sign, so we have  R3 times I3 plus I4. What we wrote down is   the basis for mesh analysis. Since we have 4  meshes in this circuit, we need 4 equations

to solve for all the unknowns. It’s always the  same, so the number of equations you need is   equal to the number of meshes in the circuit. Now the rest of mesh analysis, including loop   equations and super meshes is much easier to  teach through examples so let’s get to it. At   the end of the video, I will go over some  quick tips and notes on when to pick nodal   analysis over mesh analysis and vice versa. Let’s start with a nice and easy example where we need to find I0. We see there are 2 meshes in  this circuit, so we will need 2 equations to solve   this problem. Let’s assume our mesh currents to  travel clockwise in each mesh. It doesn’t matter   which direction you pick. If you end up with a  negative value, then you know it’s opposite to   your assumption. Since this is our first question,  we will assign voltages to each resistor. Now we   are going to write a KVL for the first mesh,  following the direction of our mesh current,

so clockwise. We see that our current would enter  the positive side of our voltage source, so it’s   positive 6 volts plus V 1 plus V 3 is equal to  zero. Keep in mind, for resistors, we always   assume that our current enters the positive side.  The next step is to define each of these voltages   using the current in our mesh and resistance  using ohms law. So voltage is equal to the current   multiplied by the resistance. For voltage 1, we  have current 1 multiplied by the 6ohm resistor.

For voltage three, we have two mesh currents  in the same branch. However, keep in mind that   we are writing our KVL for the mesh with current  I1, so I1 is the boss. That means I1 is going take   precedence, and we see that while I1 goes down,  I2 is opposing it. So I2 will get a negative sign.   Let’s simplify and that’s our first equation. Now we will write a KVL for the second mesh.  We have V 2 plus 24 Volts  plus V 3 is equal to zero.

The next step is to write our voltages in terms  of current and resistance. So V2 is I2 times 4   ohms. V3 is shared between two mesh currents.  But now, we are writing our KVL for the mesh   with current 2. That means I2 is the boss. We  see that I1 is opposing I2, so it will get a   negative sign. So we have 6 ohms times I2 minus  I1. Let’s simplify. This is our second equation.

Let’s use substitution to solve them. We  can isolate for I1 in the first equation.   Now we can plug this value into our second  equation and then directly solve for I2. Next,   we can plug in the I2 value back into  our I1 equation to get a value for I1.  We get two negative values, which means our  assumption about the directions for our mesh   currents were wrong. In other words, the mesh  currents go counter-clockwise. The question wants us to find I0, and notice that the arrow  for I0 is given to us pointing to the right,   so same direction as our mesh current. That  means I0 is also equal to I2, so negative 27/7,   not positive. If we had our mesh currents to be  counter-clockwise, we would get positive values,   but I0 would still be negative since the arrow  for I0 is given to us pointing to the right.  Let’s take a look at this question involving  current sources and voltage sources. We need

to find I0 in the circuit. We see there are  3 meshes, so we need 3 equations to solve for   unknowns. Notice we have 2 current sources in  these meshes, so we will assume the direction   of our mesh currents to be the same as the  current sources. For the other mesh current,   we can pick clockwise. So let’s look at the top  mesh. We see we have a 2mA current source. We   also see that this current source is not shared  between any branches. That means the current in

this branch must be a constant 2mA. That also  means our mesh current I2 must equal 2mA since   the mesh current has to go through the current  source, and becomes constrained to 2mA. We can   write that like this. This is our first equation. The same is true for the bottom left mesh. We have   a current source that’s not shared between  branches and it’s providing a constant 4   mA in the branch. That means our current I1  must equal 4 mA. That’s our second equation.

Now instead of writing our KVL with voltages,  we are directly going to write our KVL with   current and resistance instead. If you’re not  comfortable jumping to this step, that’s okay,   simply label the resistors with voltages and  write a KVL equation and then come to this   step like we did in the previous example. Lastly, we have the right mesh. Let’s   write our KVL equation with currents and  resistances. We have 1kohms times I3 minus I2, then we have negative 6V, and lastly 2kohms times  i3 minus i1. Why is it I3 minus I2 here? Remember,   we are writing our KVL for the mesh with current  I3, so I3 is going to be the positive value.   Notice that I2 is opposing the direction of I3, so  it will get a negative sign. Why is it negative 6   V? Notice that our current in the mesh would enter  the negative terminal of our voltage source. And

why is it I3 minus I1? It’s the same as before. I1  is opposing I3 and I3 is the boss, so it will get   a negative sign. Let’s simplify. That’s our third  equation. Just a note here k represents 1000, and   m represents 10 to the negative 3. This makes it  easier to work with rather than writing down 1000   ohms, or 2000ohms. We can solve for I3 by plugging  in I1 and I2 values. We get a positive value, so

that means our assumption for I3 was correct. Now  that we have our I3 value, we can figure out I0.   I0 is equal to mesh current 1 minus mesh current  3. Notice we have I0 going down, and while I1 is   going the same direction, we have I3 opposing it,  so I0 is equal to I1 minus I3. We get negative   1.33 mA, which means I0 is actually going upwards. Let’s take a look at this problem where we need to

find I0. We have 4 meshes in this circuit, that  means we will need 4 equations to solve for all   the unknowns. Now notice that we have 2 current  sources shared between two meshes. This is not the   same as before where the current sources were in  an independent branch. So in that case, the mesh   current direction will be an assumption, since we  don’t know the real direction of current. We can   pick all of them to be clockwise. Let’s tackle  the shared current sources first and then move

on to our KVL equation. Again, notice how all of  our current sources are shared between branches.   That means they cannot be directly equal to a  mesh current. So what can we say about I1 and I3   with respect to this 2 mA current source? We  know that the current in this branch is 2 mA,   since our current source is providing it. We  know that both mesh currents I1 and I3 added   together have to equal the branch current. But  notice that while I3 is going left to right,

so the same direction as our source, I1 is  going right to left. So that means I3 minus   I1 must equal 2 mA. That’s our first equation.  If we had picked I1 to be counter-clockwise,   then it would be I3 plus I1 is equal to 2 mA.  Either way, you will end up with the same answers.  We can do the same for the 1 mA current source.  So here, it would be I4 minus I3 is equal to 1mA   since I4 is going the same direction as our  current source. This is our second equation.

Now let’s write a KVL equation for the top right  mesh with current 2. So we have 4kohms times I2,   2kohms times I2 minus I4, and 2kohms times I2  minus I1. Keep in mind, I2 takes precedence, and   since I1 and I4 are opposing I2, they get negative  signs. Let’s simplify. This is our third equation.  We need one more equation but we can’t write any  for the remaining meshes. Why is that? Remember,

we are writing KVL equations, but we don’t know  the voltage in either of these current sources. So   instead, we are going to write a KVL for a loop.  The loop we want is one that doesn’t involve any   current sources. So the only one we can use  is this outer loop. Going clockwise, we have   4kohms times I2, plus 2kohms times I4, plus 6kohms  times I3 and lastly, we have minus 6 V since going   clockwise means we enter the negative terminal of  our voltage source. Notice that we use the mesh

current that’s associated with each resistor when  we write our loop KVL equation. This is our fourth   equation. Having all of our mesh currents going  clockwise helps because we don’t have to deal with   negative signs when it comes to our loop equation. We can now solve for all the mesh currents. If you   know how to use gaussian elimination from your  linear algebra class, this is the time to use it,   if not, you’ll be doing some annoying  substitutions or eliminations. If you want to see how these equations were  solved, please check the description.  We get a negative value for I1, which  means the current in that mesh actually   travels in the opposite direction to  our assumption, so counter-clockwise.  Now we can figure out I0. Notice we are told  I0 goes down, and in our assumed mesh currents,   I1 goes down while I2 opposes it. So I0 is  equal to I1 minus I2. That gives us -3/2 mA,

so Io is also going opposite to what’s shown.  Remember, if you have to show the real directions   of current, don’t change the directions of your  assumed currents until the question is finished.  Let’s take a look at this problem where we  need to find V0. We have 6 meshes, so we will   need 6 equations, but 2 of them are directly  given to us by the 2 current sources here.   They are not shared between any branches, and  that means we will get direct equations out of

them. So let’s draw our mesh currents,  and all of them can be clockwise.  So I3 is equal to 2 mA, and I4 is also equal  to 2 mA. They are both positive because our   mesh currents follow the same direction as  our current sources. These are our first 2   equations. Now we can focus on this current  source. What can we say about the two mesh   currents flowing in this branch? We see that  I1 goes in the same direction as the current

source while I2 goes against it. So I1 minus  I2 gives us 4mA. This is our third equation.  Next, we have this current source. So here,  I6 is going the same way as our current source   while I5 is opposing it. That means I6 minus  I5 gives us 4 mA. This is our fourth equation.  We need 2 more equations. We can’t write one  for I1, I2, I5 or I6, because we have current   sources between the branches. And we don’t know  the voltage through them. Now it’s good to look

for loops that involve the mesh currents we can’t  use to write our equations. One loop that works   is this one. It involves I5 and I6, and we don’t  need to deal with the current source. So we are   forgetting about this current source in the  middle and writing a KVL for this loop. Some   times this is called a super mesh, but really,  you are just writing KVL equations for loops.   So assuming we have a current going clockwise, we  have 1K times I5 minus I2, 1k Times I6 minus I3,

2k times I6, and negative 6 volts. Why is it  I5 minus I2? So when we write a KVL for a loop,   we are assuming a direction for current flow.  Here, we chose a clockwise direction, and notice   that I5 goes in the same direction while I2 goes  against it. So we get I5 minus I2. The same is   true for I6 and I3. I6 goes in the same direction  while I3 opposes it. Lastly, it’s negative 6   volts because our clockwise current would  enter the negative terminal of our voltage

source. Let’s simplify. This is our 5th equation. We need one more equation. For that, we can use   this loop. It covers currents I1 and I2, and we  don’t need to deal with the current source. Again,   assuming our current to flow clockwise,  we have 2kohms times I1, negative 4 volts,   1kohms times I2 minus I5, and 1kohms times I1  minus I4. Let’s simplify this equation. This is   our 6th equation. Now we can solve for our mesh  currents. If you want to see how these equations

were solved, please check the description. Now to figure V0, we need the current flowing   through this 1kOhm resistor. So that current is  I5 minus I2. Why? Notice how V0 is given with   the positive side on the left side. So i5 flows  into the positive terminal while I2 flows into   the negative terminal. The voltage is then 1kohms  multiplied by the current. And that’s our answer.

Let’s take a look at this question where we need  to find I0 in the circuit. Now we are heading into   dependent sources. So we see there are 3 meshes,  that means we will need 3 equations to solve for   all the unknowns. As usual, we can start by  drawing our mesh currents. We can assume all   of them to be clockwise. The very top mesh has  a dependant current source and it’s not shared   between any branches. So that means our mesh  current I1 has to go through the dependant

current source, so I1 is equal to 2Ix. Now where  is Ix on our circuit? It’s the current flowing   in this branch. Notice that we can write Ix as  our mesh currents. So I2 is going in the same   direction as Ix, while I3 is opposing it. That  means we can say Ix is equal to I2 minus I3.   Let’s replace Ix with the new equation. Now  we can simplify. That’s our first equation.  Next we can write a KVL equation for this  mesh. We have 1kohms times I2 minus I1,

1kohms times I2 minus I3, and -6V. Let’s  simplify. This is our second equation.  We need one more equation, and we will  write it for mesh current 3. We have   1kohms times I3 minus I1, 2Vx and 1kohms times  I3 minus I2. Now where is Vx on our circuit?   We see that it’s the voltage of this 1k ohm  resistor. So now with our thinking caps on,   we need to refer to ohms law. Voltage is equal  to the current times the resistance. So what

is the current flowing through this resistor?  It’s I2 minus I1. Why is i2 positive? Notice we   are given the positive side of our resistor, so  that means I2 enters the positive side while I1   enters the negative side. So the voltage of this  resistor is 1kohms times I2 minus I1. Let’s plug   that into our equation. Let’s simplify. That’s  our third equation. Now we can solve them. If   you want to see how it was solved, please check  the description. We got positive values, so that

means our assumptions were right. And the answer  to our question is actually already solved, I0 is   the same as I2 since it’s the same branch current. Let’s take a look at one last example where we   need to figure out I0. We see there are 6  meshes, so we need 6 equations. We can pick   all of the mesh currents to go clockwise  except for mesh current I3. That one will   go counter-clockwise so it matches with the  current source. We can see that this current

source is not shared between branches so I3  is equal to 6 mA. That’s our first equation.  We can also write an equation for the dependant  current source. We see that i6 goes in the same   direction as the current source but I5 opposes  it. So I6 minus I5 gives us 2Ix. Where is Ix   on our circuit? We see that it’s the current in  this 1k ohm resistor. Notice that this current   can be written as I4 minus I5. I4 goes in the  same direction as the labelled current while I5

opposes it. Let’s replace Ix with the new value.  Now we can simplify. That’s our second equation.  We need 4 more equations so let’s write one  for mesh current 1. We have 1kohms times I1,   12 volts, and then 1kohms times I1 minus I4.  Let’s simplify. That’s our third equation.  Next, we can write one for mesh current 2. We have  1kohms times I2 plus I3, Ikohms times I2 minus I5,   and negative 12 volts. Note this term here,  where it’s the addition of I2 and I3. Notice

how both mesh currents go in the same direction.  Let’s simplify and that’s our fourth equation.  We can write another equation for mesh current 4.  We have 1komhs times I4 minus I1, 1kohms times I4   minus I5, and 2Vx. Now since we have a dependant  voltage source with a value of 2Vx, we need to   find it on our circuit. Here is Vx. It’s the  voltage of this 1kohm resistor. So we need to   express Vx in terms of current and resistance. The  current that’s flowing through the resistor is I6,

and it has a value of 1kiloohm. So Vx is equal to  1k times I6. Let’s replace the Vx in the equation.   Now we can simplify. That’s our 5th equation. We need one more equation and we haven’t   written one for mesh currents 5 or 6. we can’t  write one for them because of the dependant   current source in the middle. So we need to  include both mesh currents and write a KVL,   and a suitable loop would be this one. We’re  ignoring the current source in the middle and

just writing an equation for the outer loop.  Assuming our currents to flow clockwise,   we have 1kohms times I5 minus I4, 1kohms  times I5 minus I2, Ik ohms times I6 plus I3,   and Ikohms times i6. Pay careful attention to  this term because notice that both I6 and I3 are   actually going the same direction in this branch,  so they are both positive. Let’s simplify. That’s   our 6th and final equation. Now we can solve these  equations. As usual, if you want to see how they

were solved, please check the description. We got some negative values, so those mesh   currents go in the opposite direction to our  assumption. To figure out I0, notice that it’s   the current in this branch. I0 is shown to go  from left to right, so it would be equal to I5   minus I2 since I5 goes in the same direction  while I2 opposes it. And that’s our answer.  Here is a circuit that looks a bit weird. But in  reality, this is just like the ones we’ve solved.

Remember, you can easily bend conductors in your  mind, or redraw it to make it look familiar.  Now, a good question to ask is, when should you  use nodal analysis, and when should you use mesh   analysis? Besides the obvious “solve using nodal  analysis, or solve using mesh analysis” you should   first analyze the circuit. Does it have more  current sources or voltage sources? If a circuit   has more current sources, it’s usually easier to  use nodal analysis since we write KCL equations.

And if a circuit has more voltage sources, it’s  usually easier to use mesh analysis since we write   KVL equations. But that’s not always the case.  Let’s look at this circuit. We have 6 meshes,   so we would need 6 equations to solve  it. If we look at nodes, we have 7 nodes,   so we would need 6 equations to solve it.  Same number of equations for both methods.   And it seems to have more voltage sources so it’s  easier to write a mesh analysis, right? No, that’s not the case here. It’s much easier to use nodal  analysis on this circuit. Why? Notice how we would   get direct values for the node voltages here since  they are directly connected to a voltage source.

That means you would already get 4 equations  out of it, meaning you will only need 2 other   equations to solve it. Look at this circuit, we  have more current sources than voltage sources.   But all of these current sources are in separate  branches that are not shared. That means you can   easily get direct equations for mesh currents  in them and you’d end up needing just 2 more   equations to solve for the unknowns. So keep  an eye out for things like that, and figure out where you can get the easiest equations. That should cover the types of problems you   will face when it comes to mesh analysis. Thanks  for watching and best of luck with your studies.

Ask anything

We've read this whole study set, so questions about it get the best answers.

FlashcardsQuizFill in the blanksWritten testLessonNotesPodcastContent