Confused about holding variables constant during integration

In summary, for a double integral, we can treat the "inner integral" separately by holding the variable ##y## constant during integration to compute something like ##\int_{x_1}^{x_2} f(x,y) dx##. This technique is also applied in other situations, such as for solving exact differential equations. There is no specific name for this method, but it can be thought of as finding partial antiderivatives.However, this strategy is not always valid. For example, in the equation ##4x - 3y = \frac{dy}{dx}##, we cannot simply hold ##y## constant and integrate both sides, as this will result in the wrong answer. In these cases, a
  • #1
etotheipi
For a double integral, we might treat the "inner integral" separately and be able to compute something like ##\int_{x_1}^{x_2} f(x,y) dx## by holding ##y## constant during the integration. The same technique is applied in other places too, like for solving exact differential equations. I haven't come across a proper name for this (partial antiderivatives?).

However, in general this doesn't appear to be a valid strategy. If I have the equation ##4x - 3y = \frac{dy}{dx}##, and rewrite this as ##\int (4x - 3y) dx = \int dy##, I can't then just hold ##y## constant on the left when I integrate both sides since evidently I'll get the wrong answer. Some other strategy needs to be used.

So why is it only permitted in some instances to hold certain variables constant? Thanks for your help!
 
Physics news on Phys.org
  • #2
The best way to see it, is to write the functions as what they are. If we have ##\int \int f(x,y)\,dx\,dy## then we only consider the inner integral first, and that is only a function in ##x##: ##\int f(x,y)\,dx = \int \phi(x) \,dx##.

In case of the differential equation, we have ##f(x,y)=\dfrac{dy}{dx}=\dfrac{d}{dx}(y)=(D(x))(y)## and there is no separation of the variables. You cannot write ##f(x,y)=\phi(x)## if ##y## is still a variable on both sides. It would work if it was ##f(x,y)=\dfrac{dz}{dx}##.
 
  • Like
Likes QuantumQuest and etotheipi
  • #3
fresh_42 said:
The best way to see it, is to write the functions as what they are. If we have ##\int \int f(x,y)\,dx\,dy## then we only consider the inner integral first, and that is only a function in ##x##: ##\int f(x,y)\,dx = \int \phi(x) \,dx##.

I think I can understand what you are saying from an operational perspective, but I'm still struggling on the rationale.

Why in the first instance does the function reduce to only one in ##x##; surely it's still dependent on ##y##?
 
  • #4
etotheipi said:
For a double integral, we might treat the "inner integral" separately and be able to compute something like ##\int_{x_1}^{x_2} f(x,y) dx## by holding ##y## constant during the integration. The same technique is applied in other places too, like for solving exact differential equations. I haven't come across a proper name for this (partial antiderivatives?).

However, in general this doesn't appear to be a valid strategy. If I have the equation ##4x - 3y = \frac{dy}{dx}##, and rewrite this as ##\int (4x - 3y) dx = \int dy##, I can't then just hold ##y## constant on the left when I integrate both sides since evidently I'll get the wrong answer. Some other strategy needs to be used.

So why is it only permitted in some instances to hold certain variables constant? Thanks for your help!
Note that if we have a function of two variables ##f(x, y)##, we can define:
$$g(y) = \int_{x_1}^{x_2} f(x, y)dx$$
"Keeping ##y## constant" is no different from replacing ##y## with a "constant". Compare the above with:
$$b = \int_{x_1}^{x_2} f(x, a)dx$$
This is mathematically the same thing. Choose a real number ##a##, carry out the integral, get a real number ##b##. That's a function. You can just as well write:
$$g(a) = \int_{x_1}^{x_2} f(x, a)dx$$
 
  • Like
Likes QuantumQuest and etotheipi
  • #5
etotheipi said:
I think I can understand what you are saying from an operational perspective, but I'm still struggling on the rationale.

Why in the first instance does the function reduce to only one in ##x##; surely it's still dependent on ##y##?
No, it is not within the limited context. The inner integral has ##y## only as dummy. We stripped the global context and considered only the local behavior of the inner integral. In case of ##3x-4y = y'## there is no way to separate ##y## and ## \;'\;##.

Another way to see it is the following:
From ##3x-4y=\dfrac{dy}{dx}## we get ## 3\int x\,dx - 4\int y(x)dx =\int 1\,dy## and we get the ##\int y(x)\,dx## term which doesn't vanish.
 
  • Like
Likes etotheipi
  • #6
fresh_42 said:
No, it is not within the limited context. The inner integral has ##y## only as dummy.

Ah okay, that seems important. I think that makes sense, even if it is still a little hard for me to recognise!

PeroK said:
This is mathematically the same thing. Choose a real number ##a##, carry out the integral, get a real number ##b##. That's a function. You can just as well write:
$$g(a) = \int_{x_1}^{x_2} f(x, a)dx$$

The logic of this is clear, it's just the bit about deciding when it's safe (is that the right word...?) to hold it constant. It appears this is when the scope of that variable is limited to that one particular part. I'll need to think a little more about this to clear things up though!

Thanks for helping!
 
  • #7
@etotheipi if you have doubts about these things, you can always go back to the formal statement of integration substituition:
$$\int_{x_1}^{x_2} y'(x) g(y(x)) dx = \int_{y(x_1)}^{y(x_2)} g(y) dy$$
In this case, if ##g## is the constant function we have:
$$\int_{x_1}^{x_2} y'(x) dx = \int_{y(x_1)}^{y(x_2)} dy$$
And the assumption on which this result is based and proved is that ##y(x)## is a single-variable function of ##x##. Your initial integral isn't of that form.
 
  • Love
Likes etotheipi
  • #8
It is always a good strategy to note dependencies explicitly. E.g. in the definition of a limit we have: for every ##\varepsilon>0## there is a ##N## such that ... Better is to write: there is a ##N(\varepsilon)## such that ...

The same is true for functions. If ##f=f(x,y)## but the integral just ##\int f(x,y) dx## then the dependencies are only in the variable ##x##. The integral cannot know what you are doing with its constants elsewhere. And from the perspective of the integral, the ##dx## determines what to integrate.
 
  • Like
  • Love
Likes QuantumQuest and etotheipi
  • #9
PeroK said:
@etotheipi if you have doubts about these things, you can always go back to the formal statement of integration substitution:

I quite like that, should be useful as a bit of a check!
fresh_42 said:
It is always a good strategy to note dependencies explicitly. E.g. in the definition of a limit we have: for every ##\varepsilon>0## there is a ##N## such that ... Better is to write: there is a ##N(\varepsilon)## such that ...

The same is true for functions. If ##f=f(x,y)## but the integral just ##\int f(x,y) dx## then the dependencies are only in the variable ##x##. The integral cannot know what you are doing with its constants elsewhere. And from the perspective of the integral, the ##dx## determines what to integrate.

Funnily enough I think @PeroK has actually also told me to do this before, so it seems like a pretty good idea! I seem to have a lot of issues similar to this when dealing with functions and derivatives and whatnot with more than one variable flying around...
 
Last edited by a moderator:
  • Like
Likes PeroK
  • #10
fresh_42 said:
If ##f=f(x,y)## but the integral just ##\int f(x,y) dx## then the dependencies are only in the variable ##x##.

Also, is this only true if ##y## is not a function of ##x##? Since otherwise I might just let ##f(x,y) = y## and we already established that ##\int y(x) dx## doesn't vanish.

I wonder if this is the key part. If ##y## is just another variable with no dependence on ##x## then I can see why we can pull it out and treat it as a constant, for reasons given in the above posts; whilst if ##y## does have a dependence on ##x##, i.e. in a differential equation, we have to be a bit more careful.
 
  • #11
etotheipi said:
Also, is this only true if ##y## is not a function of ##x##? Since otherwise I might just let ##f(x,y) = y## and we already established that ##\int y(x) dx## doesn't vanish.
Right. If ##y=y(x)## then it is no longer a constant in the integral, which is a function in ##x##. Cases ##f(y(x),x))## are dealt with in the implicit function theorem, although this lays the focus on derivatives and how to separate them.
I wonder if this is the key part. If ##y## is just another variable with no dependence on ##x## then I can see why we can pull it out and treat it as a constant, for reasons given in the above posts; whilst if ##y## does have a dependence on ##x##, i.e. in a differential equation, we have to be a bit more careful.
Yes. In this case it is no longer a constant for the integral, but part of the "integration command".
 
  • Like
Likes etotheipi
  • #12
etotheipi said:
If I have the equation ##4x - 3y = \frac{dy}{dx}##, and rewrite this as ##\int (4x - 3y) dx = \int dy##,

Why would taking an antiderivative with respect to x on the left side of an equation and taking an antiderivative with respect to y on the the right side produce an equivalent equation? It doesn't work for ##x^2 = 1##.
 
  • #13
etotheipi said:
For a double integral, we might treat the "inner integral" separately and be able to compute something like ##\int_{x_1}^{x_2} f(x,y) dx## by holding ##y## constant during the integration. The same technique is applied in other places too, like for solving exact differential equations. I haven't come across a proper name for this (partial antiderivatives?).

However, in general this doesn't appear to be a valid strategy. If I have the equation ##4x - 3y = \frac{dy}{dx}##, and rewrite this as ##\int (4x - 3y) dx = \int dy##, I can't then just hold ##y## constant on the left when I integrate both sides since evidently I'll get the wrong answer. Some other strategy needs to be used.

So why is it only permitted in some instances to hold certain variables constant? Thanks for your help!

If we have:
$$y(x) = e^{-3x} + \frac 4 3 x - \frac 4 9$$
Then:
$$4x - 3y = -3e^{-3x} + \frac 4 3$$
And:
$$\int(4x - 3y) dx = e^{-3x} + \frac 4 3 x + C = y(x) + C$$
Moreover:
$$\frac{dy}{dx} = 4x - 3y$$
Hence:
$$\int(4x - 3y) dx = \int \frac{dy}{dx} dx = \int dy = y(x) + C$$
So, as long as you are careful to treat ##y## as a function of ##x## properly this all works out.
 
Last edited:
  • #14
Stephen Tashi said:
Why would taking an antiderivative with respect to x on the left side of an equation and taking an antiderivative with respect to y on the the right side produce an equivalent equation? It doesn't work for ##x^2 = 1##.

I'm not too sure what you are saying; I integrated both sides with respect to ##x##.
PeroK said:
So, as long as you are careful to treat ##y## as a function of ##x## properly this all works out.

Thanks for this, it confirms what I suspected about the distinction.

One more thing; @fresh_42 said earlier that for ##f(x,y) = \frac{dz}{dx}##, the function ##f(x,y)## becomes essentially only a function of ##x##. How is it possible to tell in this case that ##y## is not a function of ##x##? If we were to solve it we'd get a relation between ##x,y,z## and surely that would make ##y## of the form ##y(x,z)##.
 
  • #15
etotheipi said:
One more thing; @fresh_42 said earlier that for ##f(x,y) = \frac{dz}{dx},## the function ##f(x,y)## becomes essentially only a function of ##x##. How is it possible to tell in this case that ##y## is not a function of ##x##?
It isn't. The situation ##y=y(x)## has been brought into discussion by you later IIRC. What I have said there was meant for a ##y## which doesn't depend on ##x##.
 
  • Like
Likes etotheipi
  • #16
fresh_42 said:
It isn't. The situation ##y=y(x)## has been brought into discussion by you later IIRC. What I have said there was meant for a ##y## which doesn't depend on ##x##.

Ah right, sorry! I see. I think that clears everything up that I had doubts about. Thanks everyone for your help!
 

Related to Confused about holding variables constant during integration

What does it mean to hold variables constant during integration?

Holding variables constant during integration means that you are treating them as fixed values and not allowing them to change as you integrate a function. This is often done to simplify the integration process or to analyze the effect of one variable on the overall integration.

Why is it important to hold variables constant during integration?

Holding variables constant during integration allows for a more focused analysis of the function being integrated. It can also help to isolate the effect of one variable on the overall integration, making it easier to understand and interpret the results.

What happens if a variable is not held constant during integration?

If a variable is not held constant during integration, it will be treated as a variable and allowed to change as the function is integrated. This can result in a more complex integration process and make it more difficult to analyze the effects of individual variables.

How do you determine which variables to hold constant during integration?

The decision to hold variables constant during integration depends on the specific function being integrated and the purpose of the analysis. Generally, variables that are not the main focus of the analysis or do not significantly affect the outcome of the integration can be held constant.

Are there any situations where it is not necessary to hold variables constant during integration?

Yes, there are certain cases where it is not necessary to hold variables constant during integration. For example, if the function being integrated is a constant or does not involve any variables, there is no need to hold any variables constant. Additionally, if the goal is to analyze the effect of a variable on the integration, it may be more useful to let it vary rather than holding it constant.

Similar threads

Replies
4
Views
1K
Replies
2
Views
682
Replies
1
Views
1K
  • Calculus and Beyond Homework Help
Replies
2
Views
425
Replies
29
Views
2K
  • Set Theory, Logic, Probability, Statistics
Replies
2
Views
323
  • Differential Equations
Replies
4
Views
1K
Replies
11
Views
1K
Replies
9
Views
2K
Replies
11
Views
2K
Back
Top