Exploring Why Treating Variables as Constants Fails in Line Integrals

In summary, the conversation discusses two problems involving line integrals and potential functions. It is mentioned that using the variables as constants does not give the correct answer and that the correct method involves using the product rule. It is also mentioned that scalar fields cannot be found for non-conservative fields and the method for calculating energy changes in these fields involves choosing a path and integrating along it. The conversation concludes with the speaker thanking the others for their insights and apologizing for asking potentially trivial questions due to their lack of vector calculus training.
  • #1
JackDP
7
0
Hey guys and gals, this isn't actually an assignment of any sort, so I didn't want to put it in the homework section. This is also my first post, though I have been lurking for quite a while, reading the copious amounts of information available here. :p

Anyhow, could somebody please elaborate on why it doesn't seem to work to treat the variables as a constant even though they are seemingly independent? As demonstrated below, I've tried it on two problems and both times it gives the wrong answer, though I am not sure why. I think I'm probably missing some intuition for these line integrals, and would very much appreciate a helping hand. Thanks!

Problem 1
For the field [tex]\vec{E}= 54y \mathbf{i} + 54x \mathbf{j} + 3 \mathbf{k}[/tex] find the potential function [tex]V_E(x,y,z)[/tex].
[tex]V_E(x,y,z) = -\int \vec{E}\bullet \vec{ds}
= - \int (54y \mathbf{i} + 54x \mathbf{j} + 3 \mathbf{k}) \bullet (dx\mathbf{i} + dy \mathbf{j}+ dz\mathbf{k})
= - \int (54y\ dx + 54x\ dy + 3\ dz)[/tex]

[tex]\therefore V_E(x,y,z)= - 108xy - 3z + C[/tex]

But according to the book, the answer is actually [tex]V_E(x,y,z) = -54xy - 3z[/tex]

***

Problem 2
Suppose our field [tex]\vec{E} = \dfrac{F}{a^2}(yz \mathbf{i} + xz \mathbf{j} + xy \mathbf{k})[/tex], where F and a are constants. Calculate the potential difference [tex]\Delta V_E[/tex] between the origin and the point (1,1,1) along the straight line given by the formula (s, s, s), where the variable s runs from 0 to 1.

Using the same method as above, [tex]V_E(x,y,z) = - \dfrac{F}{a^2}\int (yz\ dx + xz\ dy + xy\ dz) = - \dfrac{3F}{a^2}(xyz) + C[/tex]

[tex]\Rightarrow \Delta V_E = V_E(1,1,1) - V_E(0,0,0) = - \dfrac{3F}{a^2}[/tex]


However, this is wrong, according to the book, and is out by a factor of three. Using a different method, spotting that along the line, x=y=z, leads to a different integral for the potential: [tex]V_E(x,y,z) = - \dfrac{F}{a^2}\int (xx\ dx + xx\ dx + xx\ dx) = - \dfrac{F}{a^2}\int (3x^2\ dx) = - \dfrac{F}{a^2}x^3[/tex]

[tex]\therefore \Delta V_E = - \dfrac{F}{a^2}[/tex]

This is the correct answer, according to the book.
 
Physics news on Phys.org
  • #2


Those line integrals can't, in general, be computed like a normal integral as you did there.

In the first case, for instance, you ignored the fact that you need limits of integration. The potential is relative to zero potential at infinite distance-- you need to do the line integral from infinity to point (x, y, z). You can't simply integrate. Easier to solve it this: find the function whose gradient gives you the desired E-field. After some squinting, you see it must be the books solution.

In the second case, your realization that x=y=z is correct. It's called parameterizing the integral, and you must always do it for a line integral.
 
  • #3


Your mistake in the first question is in the last line. This is how the reasoning should go: using the product rule, –54ydx + –54xdy = –54(ydx +xdy) = –54d(xy), which integrates directly to –54xy.

In the second question, your method is fine in principle (and, imo, very much nicer than the textbook's method), but you've made a mistake in the execution. Your factor of 3 simply shouldn't be there. Again, using the product rule,
d(xyz) = yzdx + zxdy + xydz. I'll do a thumbnail to show this, if requested.

[These examples are for 'conservative' E fields, arising from configurations of static charges. 'Conservative' means that the same amount of work is done by the field on a 'testing' charge going from point A to point B, by whatever path you choose. It is only because of this that you get these neat integrations' leading to a scalar field, V(x, y, z). Such a function of position does not exist for an E arising from changing magnetic flux, and different quantities of work done for different choices of paths between A and B.]
 
Last edited:
  • #4


Philip Wood said:
Your mistake in the first question is in the last line. This is how the reasoning should go: using the product rule, –54ydx + –54xdy = –54(ydx +xdy) = –54d(xy), which integrates directly to –54xy.

In the second question, your method is fine in principle (and, imo, very much nicer than the textbook's method), but you've made a mistake in the execution. Your factor of 3 simply shouldn't be there. Again, using the product rule,
d(xyz) = yzdx + zxdy + xydz. I'll do a thumbnail to show this, if requested.

[These examples are for 'conservative' E fields, arising from configurations of static charges. 'Conservative' means that the same amount of work is done by the field on a 'testing' charge going from point A to point B, by whatever path you choose. It is only because of this that you get these neat integrations' leading to a scalar field, V(x, y, z). Such a function of position does not exist for an E arising from changing magnetic flux, and different quantities of work done for different choices of paths between A and B.]
Interesting, both failures are due to the same thing really aren't they? Though I see immediately that the right answer comes out when the product rule is used, I am confused as to why it doesn't work without this - as the two are equal, are they not? Nevertheless, thank you for that insight as I can now see where the answers came from, and I'm also glad to see that what I felt was the "natural" method seems to work for the conservative fields.

If scalar fields can't be found, how does one calculate the energy changes for a non-conservative field, such as a changing magnetic field? Sorry for asking probably such trivial questions, as well, I just start my physics degree in October so haven't had any vector calculus training as yet.

Thanks again!
 
  • #5


JackDP said:
as the two are equal, are they not?
Which two?

JackDP said:
If scalar fields can't be found, how does one calculate the energy changes for a non-conservative field, such as a changing magnetic field?
You choose the path you're interested in, and integrate round that path, probably using a parameter.

JackDP said:
Sorry for asking probably such trivial questions, as well, I just start my physics degree in October so haven't had any vector calculus training as yet.

There's nothing trivial about your questions. Well done for doing some work in advance of your degree. I'm sure you'll do very well.
 
  • #6


I think working in terms of differentials can be tricky though, especially with the fact that things are generally parameterized and not integrated directly like that. It's why the gradient method is probably safer, as I described above.
 
  • #7


I'd say it depended on the problem, and spotting 'exact differentials' is quick and rigorous - in cases like your two examples where there are exact differentials.

Why I don't like the textbook method as much as JackDP's for the second problem is that integrating along a particular line doesn't show that you get the same answer whichever path you choose, that is it doesn't show that the field is conservative. [It's fine, of course, if you already know that the field is conservative, for example if you know that it arises from static charges.]
 
Last edited:
  • #8


Philip Wood said:
Which two?You choose the path you're interested in, and integrate round that path, probably using a parameter.



There's nothing trivial about your questions. Well done for doing some work in advance of your degree. I'm sure you'll do very well.

I meant that [tex]x\ dy + y\ dx = d(xy)[/tex] and therefore I don't understand why you have need to use the exact RHS to get the correct answer out? And likewise for the other differentials.

Ah right, so it's all line integrals then. Sounds fun. :P

Thanks, I hope so! It will be tough, no doubt, but I love physics, so I will do what it takes to do well; I want to understand these beautiful things!
 
  • #9


It's because d(anything) integrates to (that thing). So dx integrates to x. And d(xy) integrates to xy. But you can't integrate xdy by itself unless you know how x varies with y, that is unless you choose an integration path. The same goes for ydx. But if you have xdy together with ydx, then the combination is equal to d(xy), whose (indefinite) integral is xy, and which is clearly, therefore, path independent.

No need to parametrise in such cases. Please also see my previous post.
 
  • #10


Philip Wood said:
It's because d(anything) integrates to (that thing). So dx integrates to x. And d(xy) integrates to xy. But you can't integrate xdy by itself unless you know how x varies with y, that is unless you choose an integration path. The same goes for ydx. But if you have xdy together with ydx, then the combination is equal to d(xy), whose (indefinite) integral is xy, and which is clearly, therefore, path independent.

No need to parametrise in such cases. Please also see my previous post.

Ahhhh that makes perfect sense! So would it be accurate to say that (for conservative fields):

- whenever you aren't integrating on a path, you have to use an exact derivative as you don't know the relationship between x,y,z?

- when you choose a path, then you know how x,y,z vary wrt each other, and so can integrate without an exact derivative after substituting the variables (i.e. like x=y=z in "Problem 2")?

I cannot thank you enough, my friends and I were deliberating this for hours last night and could come up with no reasonable explanation as to where we were making an error.
 
  • #11


Yes!
The concepts of exact and inexact differentials are important in studying fields, and also in thermodynamics. To have grasped them in advance puts you at a considerable advantage. Good luck!
 
  • #12


Philip Wood said:
Yes!
The concepts of exact and inexact differentials are important in studying fields, and also in thermodynamics. To have grasped them in advance puts you at a considerable advantage. Good luck!

Thank you for your help, kind sir! :smile:
 

1. Why is it important to treat variables as constants in line integrals?

It is important to treat variables as constants in line integrals in order to accurately calculate the value of the line integral. When variables are treated as constants, the integral becomes a simple multiplication, making it easier to solve. This also ensures that the integral is not affected by changes in the variable values.

2. What happens if variables are not treated as constants in line integrals?

If variables are not treated as constants in line integrals, the result of the integral will be incorrect. This is because the variable values can change, making the integral more complex and difficult to solve. Additionally, the integral may be affected by external factors, such as the domain of the function.

3. Can treating variables as constants ever fail in line integrals?

Yes, treating variables as constants can fail in line integrals in certain cases. This usually occurs when the function being integrated is not continuous or has a discontinuity at some point along the line. In these cases, treating variables as constants may result in an incorrect answer.

4. How can one identify when treating variables as constants will fail in line integrals?

To identify when treating variables as constants will fail in line integrals, one should check for discontinuities or sharp turns in the function being integrated. Additionally, if the function is not continuous over the entire line, treating variables as constants may not yield the correct result.

5. Are there any alternatives to treating variables as constants in line integrals?

Yes, there are alternative methods for solving line integrals that do not involve treating variables as constants. One method is to use a different coordinate system, such as polar or spherical coordinates, which can simplify the integral. Another method is to use the Fundamental Theorem of Calculus, which allows for the integration of a function along a closed path.

Similar threads

  • Calculus and Beyond Homework Help
Replies
2
Views
365
  • Calculus and Beyond Homework Help
Replies
2
Views
237
  • Calculus and Beyond Homework Help
Replies
1
Views
483
  • Calculus and Beyond Homework Help
Replies
10
Views
418
  • Calculus and Beyond Homework Help
Replies
2
Views
1K
Replies
8
Views
783
Replies
2
Views
1K
  • Introductory Physics Homework Help
Replies
10
Views
770
  • Calculus and Beyond Homework Help
Replies
3
Views
1K
  • Calculus and Beyond Homework Help
Replies
2
Views
136
Back
Top