Author Topic: Mesh analysis  (Read 34152 times)

0 Members and 1 Guest are viewing this topic.

Offline IanB

  • Super Contributor
  • ***
  • Posts: 11859
  • Country: us
Re: Mesh analysis
« Reply #50 on: December 31, 2016, 06:26:08 pm »
Well for the nodal analysis the voltage source throws it right out. The resistance is 0 and you can't devide by 0 to get the current. I can't put a voltage into the equation. So does that make it a system of 3 equations ?

I'm not quite sure if you are reading what people have been saying here to help you?

For example, right above your post:

Think in terms of nodes and the elements that connect them. Imagine two nodes, a and b, and some element that joins them. Depending on the connecting element, you get an equation:

Connected by a resistor R -->  I_ab = (V_b - V_a) / R
Connected by a current source Is --> I_ab = Is
Connected by a voltage source V --> a - b = V

When there is a voltage source you cannot use Ohm's law, but you can write an equation about the difference of the adjacent node voltages.

It is important to pause and reflect on what people write and not skip over things in a panic.
 

Online SimonTopic starter

  • Global Moderator
  • *****
  • Posts: 17814
  • Country: gb
  • Did that just blow up? No? might work after all !!
    • Simon's Electronics
Re: Mesh analysis
« Reply #51 on: December 31, 2016, 07:35:33 pm »
Well this is where it gets confusing because the theory says to assume all being summed or subtracted and let the signs take care of themselves. a +K would probably end up as +-k or would the + still throw it ?
 

Offline IanB

  • Super Contributor
  • ***
  • Posts: 11859
  • Country: us
Re: Mesh analysis
« Reply #52 on: December 31, 2016, 07:54:39 pm »
Well this is where it gets confusing because the theory says to assume all being summed or subtracted and let the signs take care of themselves. a +K would probably end up as +-k or would the + still throw it ?

In your original diagram the voltages have arrows indicating their direction. Here, "direction" in AC terms has the same meaning as "sign" in DC terms. So for example, if the arrow on V3 points from b to a, then the equation becomes:

    V3 = Va - Vb

However, if the arrow happened to point from a to b, then the equation would be:

    V3 = Vb - Va

If you do this then everything will work out appropriately.
 

Online SimonTopic starter

  • Global Moderator
  • *****
  • Posts: 17814
  • Country: gb
  • Did that just blow up? No? might work after all !!
    • Simon's Electronics
Re: Mesh analysis
« Reply #53 on: December 31, 2016, 07:56:31 pm »
well yes voltages have direction and are given. But the theory told me to subtract all terms or add them. Now if I make K negative in the second equation i get a totally different result. This is a bloody minefield.
 

Offline orolo

  • Frequent Contributor
  • **
  • Posts: 352
  • Country: es
Re: Mesh analysis
« Reply #54 on: December 31, 2016, 07:57:34 pm »
Well this is where it gets confusing because the theory says to assume all being summed or subtracted and let the signs take care of themselves. a +K would probably end up as +-k or would the + still throw it ?
The theory says that you must add all the currents converging into the node.

In order to do that, you must make sure that the currents are incoming into that node, consistent with the global orientation you chose for the circuit.

For example, when writing the equation for the left node, you did:

left node: (120-x)/2 + (0-x)/(-i5) + k + (-14.14-i14.14)/(-i5) = 0

Since you are adding all these currents, you are using the fact that they are converging into node x:   a <---(k)--- b, and also:  a <---(-14.14-i14.14)/(-i5)--- b

When it's time to write the equation for node 'y', you must add currents converging into that node, so:

a <---(k)--- b turns into:  a ---(-k)---> b   
a <---(-14.14-i14.14)/(-i5)--- b   turns into:    a ---(14.14+14.14i)---> b

Note that   a <---(k)--- b  and    a ---(-k)---> b   are saying exactly the same, but in order to add currents converging into the node, you must choose the latter. So the equation is:

right node: (i120-y)/4 + (0-y)/(i4) - k + (14.14+i14.14)/(-i5) = 0

So, yes, in the second eqation you used +(-k) = -k.

Anyway, for me it works better to choose a clear orientation for each wire and separately add incoming and outgoing currents in each node.




 

Online SimonTopic starter

  • Global Moderator
  • *****
  • Posts: 17814
  • Country: gb
  • Did that just blow up? No? might work after all !!
    • Simon's Electronics
Re: Mesh analysis
« Reply #55 on: December 31, 2016, 07:58:01 pm »
(posted while previous post was being written)

I can't know which way every current goes until I do the math. This case is rather awkward as both sources are the same voltage albeit 90 degrees out of phase. I suppose the only certainty with K is that because it IS driven by a voltage of known sign it's direction is known
« Last Edit: December 31, 2016, 08:00:38 pm by Simon »
 

Online SimonTopic starter

  • Global Moderator
  • *****
  • Posts: 17814
  • Country: gb
  • Did that just blow up? No? might work after all !!
    • Simon's Electronics
Re: Mesh analysis
« Reply #56 on: December 31, 2016, 08:00:03 pm »
I see so the equations need to work with each other. So ait does not matter the sign of K but that it's oposite as it can't enter or exit both nodes.
 

Offline IanB

  • Super Contributor
  • ***
  • Posts: 11859
  • Country: us
Re: Mesh analysis
« Reply #57 on: December 31, 2016, 08:03:32 pm »
I can't know which way every current goes until I do the math. This case is rather awkward as both sources are the same voltage albeit 90 degrees out of phase. I suppose the only certainty with K is that because it IS driven by a voltage of known sign it's direction is known

But you don't need to wait until the end to find out which way each current goes, you can choose this for yourself right at the start. Simply draw an arrow on the diagram next to each current path, and whichever way that arrow points, that is the way the current goes. Then write down the equations accordingly.

After you have solved everything, it might turn out that some currents have negative values. This is perfectly fine. If a current has a negative value it is simply going in the opposite direction of the arrow.

(And I made a blunder in that last paragraph! When you are dealing with complex numbers in AC theory there are no negative and positive numbers. Complex numbers do not have a sign!  :)  )
« Last Edit: December 31, 2016, 08:05:30 pm by IanB »
 

Offline rstofer

  • Super Contributor
  • ***
  • Posts: 9889
  • Country: us
Re: Mesh analysis
« Reply #58 on: December 31, 2016, 08:07:54 pm »
If you swap the signs of the k terms, both of them together, you will get different answer for the k result.  The signs of the terms will swap.
For your original equations, I got something like -29+43i but when I make a different assumption for k (now negative in the node x equation), I get 29-43i.

Which leads me to a question:  When we do this stuff for DC, it is obvious when we have an incorrect assumption because the sign of the real number will be negative.  How do we tell in the case of AC and complex numbers?  Do we just look at the real component?
 

Offline kulky64

  • Regular Contributor
  • *
  • Posts: 61
  • Country: sk
Re: Mesh analysis
« Reply #59 on: December 31, 2016, 08:17:19 pm »
Which leads me to a question:  When we do this stuff for DC, it is obvious when we have an incorrect assumption because the sign of the real number will be negative.  How do we tell in the case of AC and complex numbers?  Do we just look at the real component?

Modulus of complex number will be the same, but the phase will be 180 degrees shifted.
 

Offline IanB

  • Super Contributor
  • ***
  • Posts: 11859
  • Country: us
Re: Mesh analysis
« Reply #60 on: December 31, 2016, 08:21:47 pm »
If you swap the signs of the k terms, both of them together, you will get different answer for the k result.  The signs of the terms will swap.
For your original equations, I got something like -29+43i but when I make a different assumption for k (now negative in the node x equation), I get 29-43i.

Which leads me to a question:  When we do this stuff for DC, it is obvious when we have an incorrect assumption because the sign of the real number will be negative.  How do we tell in the case of AC and complex numbers?  Do we just look at the real component?

The current doesn't have an "absolute" value like -29+43i or 29-43i; rather the current is expressed relative to some reference voltage and it leads or lags this voltage. So for example if we look at the direction arrow on V3, then this sets what should happen to the current in the V3 branch relative to this arrow. Given the direction of the arrow, there is only one possible outcome.
 

Offline kulky64

  • Regular Contributor
  • *
  • Posts: 61
  • Country: sk
Re: Mesh analysis
« Reply #61 on: December 31, 2016, 08:24:03 pm »
Calculating nodal voltages is easy:
 
The following users thanked this post: orolo

Online SimonTopic starter

  • Global Moderator
  • *****
  • Posts: 17814
  • Country: gb
  • Did that just blow up? No? might work after all !!
    • Simon's Electronics
Re: Mesh analysis
« Reply #62 on: December 31, 2016, 08:26:40 pm »
yes but just putting -K instead of +K in one equation completey changes the absolute numbers and their signs. So on the one hand the theory I was given says just add everything OR subtract everything and if you add them all the currents that instead leave the node and there will be at least one will come negative. Or does this only apply to actual numbers or expresions with numbers and not to variables or constants (we define the voltages to ground 0-x and 0-y in order to effectively get -x and -y)
 

Offline rstofer

  • Super Contributor
  • ***
  • Posts: 9889
  • Country: us
Re: Mesh analysis
« Reply #63 on: December 31, 2016, 08:54:00 pm »
yes but just putting -K instead of +K in one equation completey changes the absolute numbers and their signs. So on the one hand the theory I was given says just add everything OR subtract everything and if you add them all the currents that instead leave the node and there will be at least one will come negative. Or does this only apply to actual numbers or expresions with numbers and not to variables or constants (we define the voltages to ground 0-x and 0-y in order to effectively get -x and -y)

If you swap the signs of K in both places, no change occurs to Vx or Vy.  Only the value of K changes from +Re -Im to -Re +Im.  A 180 degree phase change as would be expected.
 

Offline rstofer

  • Super Contributor
  • ***
  • Posts: 9889
  • Country: us
Re: Mesh analysis
« Reply #64 on: December 31, 2016, 08:55:46 pm »
The result of that in microsoft mathematica is attached - I'm sure this is yet another version of the many I have tried and might have done a better job this time as the difference between the voltages at the nodes actually looks like 14.14+i14.14

BTW, nice use of Microsoft Mathematics!
 

Online SimonTopic starter

  • Global Moderator
  • *****
  • Posts: 17814
  • Country: gb
  • Did that just blow up? No? might work after all !!
    • Simon's Electronics
Re: Mesh analysis
« Reply #65 on: December 31, 2016, 09:04:22 pm »
yes but just putting -K instead of +K in one equation completey changes the absolute numbers and their signs. So on the one hand the theory I was given says just add everything OR subtract everything and if you add them all the currents that instead leave the node and there will be at least one will come negative. Or does this only apply to actual numbers or expresions with numbers and not to variables or constants (we define the voltages to ground 0-x and 0-y in order to effectively get -x and -y)

If you swap the signs of K in both places, no change occurs to Vx or Vy.  Only the value of K changes from +Re -Im to -Re +Im.  A 180 degree phase change as would be expected.


Well this all comes down to the deep theory of this sort of analysis that was not covered in my course material, they did similar circuits without the "extra" voltage source and with one vertical branch. the whole concept of an extra constant voltage thrown in there and turning what would have been a 2 term equation setup into a 3 equation one. I'd have never have gotten anywhere without the help here. Once again I have learnt more trying to do the assignment than reading tens of pages of meaningless maths.

At present the course is going something like:

read course material - forget all the deap maths as there is 200 pages of drivel
get totally confused and consult a real book.
attempt assignment only to discover that the course material too 100 pages to explain what could have been explained in 20 pages and that I need more information than the course material gives despite it being 5 times the amount of material required and start reasding the book and consulting the forum. This is a very long winded process. I am on the verge of abandoning the course material and jiuat studying for each question using the book and forum.
 

Online SimonTopic starter

  • Global Moderator
  • *****
  • Posts: 17814
  • Country: gb
  • Did that just blow up? No? might work after all !!
    • Simon's Electronics
Re: Mesh analysis
« Reply #66 on: December 31, 2016, 09:08:20 pm »
The result of that in microsoft mathematica is attached - I'm sure this is yet another version of the many I have tried and might have done a better job this time as the difference between the voltages at the nodes actually looks like 14.14+i14.14

BTW, nice use of Microsoft Mathematics!


Yea, they managed to turn out a program that is user friendly and does not need a session of RTFM before you can get anything done.
 

Offline rstofer

  • Super Contributor
  • ***
  • Posts: 9889
  • Country: us
Re: Mesh analysis
« Reply #67 on: December 31, 2016, 09:47:34 pm »
The result of that in microsoft mathematica is attached - I'm sure this is yet another version of the many I have tried and might have done a better job this time as the difference between the voltages at the nodes actually looks like 14.14+i14.14

BTW, nice use of Microsoft Mathematics!

Yea, they managed to turn out a program that is user friendly and does not need a session of RTFM before you can get anything done.
We have been using it for my grandson't PreCalc class for the past two semesters.  We mostly use it to plot functions rather than crunch numbers.

For some mysterious reason, they messed up the graphics and the calculator interface is very difficult to use on high res displays.  This could also be a problem with Win10, I wouldn't know.  I need to install it on a machine with a 1024x768 display to see if it looks better.
 

Online SimonTopic starter

  • Global Moderator
  • *****
  • Posts: 17814
  • Country: gb
  • Did that just blow up? No? might work after all !!
    • Simon's Electronics
Re: Mesh analysis
« Reply #68 on: December 31, 2016, 10:13:14 pm »
yes the display is a bit small on the calculator. It's a 2010 vintage program so probably not designed to work well with screen magnification or they just buggered it up.
 

Offline rstofer

  • Super Contributor
  • ***
  • Posts: 9889
  • Country: us
Re: Mesh analysis
« Reply #69 on: December 31, 2016, 10:22:05 pm »

Well this all comes down to the deep theory of this sort of analysis that was not covered in my course material, they did similar circuits without the "extra" voltage source and with one vertical branch. the whole concept of an extra constant voltage thrown in there and turning what would have been a 2 term equation setup into a 3 equation one. I'd have never have gotten anywhere without the help here. Once again I have learnt more trying to do the assignment than reading tens of pages of meaningless maths.


I think this has been the most interesting thread on the Forum in the several months I have been here.  It's about the tools!  Look at all the neat ways to solve these equations.  Writing the loop equations is pretty straightforward (well, that 3rd source is a PITA) but the real issue is getting a solution.  That may not be important for the course work but what we've done with Maxima, Matlab and Microsoft Mathematics has been hugely educational.  I have learned a lot!

Oh, BTW, there are some very talented folks visiting this thread!
 

Offline IanB

  • Super Contributor
  • ***
  • Posts: 11859
  • Country: us
Re: Mesh analysis
« Reply #70 on: January 01, 2017, 11:30:11 am »
Having read through this thread, I thought I would just add my take on how I would approach it. It seems to me that an important part of the solution process is to start from first principles and only later try to simplify things down. To that end I wrote it out as attached, using the absolute basic theory of current balances around the nodes. One thing to note is that there is no issue with sign conventions (the labels on the drawing clarify that), and there is no new variable "K" appearing (no need).

I have to be sure omitted all the later stages of substitution, simplification and numerical calculation, but those things are quite mechanical. They don't really touch on the core theory of the problem.

(NOTE: I buggered up equations 4 and 8. They should be:

  i1 = (V1 - Va) / Z1                    ( 4 )

  i6 = (V2 - Vb) / Z3                    ( 8 )

Sorry about that. I should have checked my work.)
« Last Edit: January 01, 2017, 11:33:50 am by IanB »
 
The following users thanked this post: orolo

Offline snarkysparky

  • Frequent Contributor
  • **
  • Posts: 414
  • Country: us
Re: Mesh analysis
« Reply #71 on: January 01, 2017, 04:24:48 pm »
Just define a current in each branch with an arrow showing its direction.

Make equations with KCL summing the current into each node = 0

Make equations with KVL  going around loops.  I use convention that going from minus to plus is a positive voltage step.
Keep the same direction as you write terms around the loop. 

When going across an element in the same direction as the defined current this will be a negative voltage because the convention that follows what you would expect if it was just a resistor. It is a drop in the direction you are traveling.
You can at a first step ignore all the values of the impedances, just label them as Z1,Z2........ and fill them in later.  It helps sometimes because the minus in complex impedances can confuse.

So when crossing an element opposite the direction of your labeled current the drop will be a plus voltage.

Count the number of unknown variables.  If you have the same number of independent equations you are done with the hard part.  Just solve those babies.

It takes practice. Lots of practice..
 

Offline kulky64

  • Regular Contributor
  • *
  • Posts: 61
  • Country: sk
Re: Mesh analysis
« Reply #72 on: January 01, 2017, 05:20:16 pm »
Having read through this thread, I thought I would just add my take on how I would approach it. It seems to me that an important part of the solution process is to start from first principles and only later try to simplify things down. To that end I wrote it out as attached, using the absolute basic theory of current balances around the nodes. One thing to note is that there is no issue with sign conventions (the labels on the drawing clarify that), and there is no new variable "K" appearing (no need).

I have to be sure omitted all the later stages of substitution, simplification and numerical calculation, but those things are quite mechanical. They don't really touch on the core theory of the problem.

(NOTE: I buggered up equations 4 and 8. They should be:

  i1 = (V1 - Va) / Z1                    ( 4 )

  i6 = (V2 - Vb) / Z3                    ( 8 )

Sorry about that. I should have checked my work.)


Unfortunately you buggered equations 3, 4, 6 and 8 (equations 4 and 8 are still wrong even after your "correction"). They should be:
  V3 = - Va + Vb                          ( 3 )
  i1 = (- V1 - Va) / Z1                  ( 4 )
  i2 = - V3 / Z2                            ( 6 )
  i6 = (- V2 - Vb) / Z3                  ( 8 )
 

Offline rstofer

  • Super Contributor
  • ***
  • Posts: 9889
  • Country: us
Re: Mesh analysis
« Reply #73 on: January 01, 2017, 06:01:08 pm »
Calculating nodal voltages is easy:

I have been staring at these equations for a couple of hours and I think I'm stuck.

IZ1 = V1 / Z1 = 60A
IZ3 = V3 / Z3 = 30A

I can see where these would be true if V10 and V20 was 0V but that isn't the case.  Suppose the circuit beyond Z1 and Z4 didn't even exist.  The current certainly wouldn't be 60A.

I'm missing something...
« Last Edit: January 01, 2017, 06:03:04 pm by rstofer »
 

Offline kulky64

  • Regular Contributor
  • *
  • Posts: 61
  • Country: sk
Re: Mesh analysis
« Reply #74 on: January 01, 2017, 06:10:30 pm »
Calculating nodal voltages is easy:

I have been staring at these equations for a couple of hours and I think I'm stuck.

IZ1 = V1 / Z1 = 60A
IZ3 = V3 / Z3 = 30A

I can see where these would be true if V10 and V20 was 0V but that isn't the case.  Suppose the circuit beyond Z1 and Z4 didn't even exist.  The current certainly wouldn't be 60A.

I'm missing something...

I can guarantee they are correct. I attached simulation from Tina-TI. I chose frequency 50 Hz and calculated capacitor and inductor values accordingly. I highlighted in red my manually calculated values of V10, V20 and Is.
« Last Edit: January 01, 2017, 06:30:08 pm by kulky64 »
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf