Assistance needed for this ODE problem

In summary, the conversation discusses a problem in the first order ODEs section of Boyce & DiPrima's Elementary Diff Eq (5th Ed). It introduces the concept of variation of parameters and involves finding A(x) from (i) and substituting it into (ii). The solution is then verified with (iii). The conversation delves into integrating equation (i) and performing integration by parts to find A(x). However, there is an error in the integration by parts as the differential for dv is incorrect. This leads to an incorrect solution in (iv) compared to (iii). The conversation ends with a request for assistance in identifying the error.
  • #1
heaviside
2
0
Hi,The problem I am trying to solve is in a section on first order ODEs. It is problem 25 in section 2.1 of Boyce & DiPrima's Elementary Diff Eq (5th Ed). The problem serves as an introduction to the variation of parameters, but again, it is in the first section of the book that introduces first order ODEs.

Find A(x) from (i). Then substitute for A(x) in (ii). Verify that the solution verifies with (iii).

(i)
\(\displaystyle
A'(x) = g(x) \exp \lbrack \int p(x)\,dx \rbrack
\)

(ii)
\(\displaystyle
y = A(x) \exp \lbrack -\int p(x)\,dx \rbrack
\)

(iii)
\(\displaystyle
y = \frac{\int \mu(x)g(x)dx + c}{\mu(x)}
\)

This is what I have so far:

Integrate (by parts) equation (i):
\(\displaystyle
\int udv = uv-\int vdu
\)
Let
\(\displaystyle u = \exp \lbrack \int p(x)\,dx \rbrack \)
\(\displaystyle du = p(x) \exp \lbrack \int p(x)\,dx \rbrack \)
\(\displaystyle v = g(x) \)
\(\displaystyle dv=g'(x) \)

This yields:
\(\displaystyle
A(x)=g(x) \exp \lbrack \int p(x)\,dx \rbrack - \int g(x)p(x) \exp \lbrack \int p(x)\,dx \rbrack dx
\)

Putting this into equation (ii), yields:
\(\displaystyle
y = \lgroup g(x) \exp \lbrack \int p(x)\,dx \rbrack - \int g(x)p(x) \exp \lbrack \int p(x)\,dx \rbrack dx \rgroup \bullet \exp \lbrack - \int p(x)\,dx \rbrack
\)
and thus (iv)
\(\displaystyle
y = g(x) - \lgroup \int g(x)p(x) \exp \lbrack \int p(x)\,dx \rbrack dx \rgroup \bullet \exp \lbrack - \int p(x)\,dx \rbrack
\)

Now, I perform integration by parts again on the term in round brackets above:
Let
\(\displaystyle u = g(x) \)
\(\displaystyle du = g'(x)\)
\(\displaystyle v = \exp \lbrack \int p(x)\,dx \rbrack \)
\(\displaystyle dv = p(x) \exp \lbrack \int p(x)\,dx \rbrack \)

This yields:
\(\displaystyle
g(x)\exp \lbrack \int p(x)\,dx \rbrack - \int g'(x) \exp \lbrack \int p(x)\,dx \rbrack dx
\)

Now (iv) becomes
\(\displaystyle
y = g(x) - \lgroup g(x)\exp \lbrack \int p(x)\,dx \rbrack - \int g'(x) \exp \lbrack \int p(x)\,dx \rbrack dx \rgroup \exp \lbrack - \int p(x)\,dx \rbrack
\)
Simplifying:
\(\displaystyle
y = \frac{\int g'(x)\exp \lbrack \int p(x)\,dx \rbrack dx}{\exp \lbrack \int p(x)\,dx \rbrack}
\)

Now the book defines
\(\displaystyle
\mu(x) = \exp \lbrack \int p(x)\,dx \rbrack
\)

Therefore, what I have is:
\(\displaystyle
y=\frac{\int \mu(x)g'(x)dx + c}{\mu(x)}
\)

Compare this to (iii) - you will see I have \(\displaystyle g'(x)\) instead of \(\displaystyle g(x)\).

So my question is: where did I go wrong. I've been looking over this for hours.

Thanks,
heaviside
 
Physics news on Phys.org
  • #2
Re: Assistance needed for this ODE problame

heaviside said:
Hi,The problem I am trying to solve is in a section on first order ODEs. It is problem 25 in section 2.1 of Boyce & DiPrima's Elementary Diff Eq (5th Ed). The problem serves as an introduction to the variation of parameters, but again, it is in the first section of the book that introduces first order ODEs.

Find A(x) from (i). Then substitute for A(x) in (ii). Verify that the solution verifies with (iii).

(i)
\(\displaystyle
A'(x) = g(x) \exp \lbrack \int p(x)\,dx \rbrack
\)

(ii)
\(\displaystyle
y = A(x) \exp \lbrack -\int p(x)\,dx \rbrack
\)

(iii)
\(\displaystyle
y = \frac{\int \mu(x)g(x)dx + c}{\mu(x)}
\)

This is what I have so far:

Integrate (by parts) equation (i):
\(\displaystyle
\int udv = uv-\int vdu
\)
Let
\(\displaystyle u = \exp \lbrack \int p(x)\,dx \rbrack \)
\(\displaystyle du = p(x) \exp \lbrack \int p(x)\,dx \rbrack \)
\(\displaystyle v = g(x) \)
\(\displaystyle dv=g'(x) \)

I'm assuming you meant $dv = g'(x) \, dx$. Remember the Golden Rule of Differentials: if you have a differential on one side of an equation, you must have a differential on the other side as well.

This is not what you have in your integral. For by-parts, the integral you start with has to be the $\displaystyle \int u \, dv$. So you're saying, by setting up the by-parts this way, that your original integral is $\displaystyle \int g'(x) e^{ \int p(x) \, dx} \, dx$. But it isn't. Your original integral is $\displaystyle \int g(x) e^{ \int p(x) \, dx} \, dx$.

Try propagating this correction through your derivations, and see if it comes out right.

This yields:
\(\displaystyle
A(x)=g(x) \exp \lbrack \int p(x)\,dx \rbrack - \int g(x)p(x) \exp \lbrack \int p(x)\,dx \rbrack dx
\)

Putting this into equation (ii), yields:
\(\displaystyle
y = \lgroup g(x) \exp \lbrack \int p(x)\,dx \rbrack - \int g(x)p(x) \exp \lbrack \int p(x)\,dx \rbrack dx \rgroup \bullet \exp \lbrack - \int p(x)\,dx \rbrack
\)
and thus (iv)
\(\displaystyle
y = g(x) - \lgroup \int g(x)p(x) \exp \lbrack \int p(x)\,dx \rbrack dx \rgroup \bullet \exp \lbrack - \int p(x)\,dx \rbrack
\)

Now, I perform integration by parts again on the term in round brackets above:
Let
\(\displaystyle u = g(x) \)
\(\displaystyle du = g'(x)\)
\(\displaystyle v = \exp \lbrack \int p(x)\,dx \rbrack \)
\(\displaystyle dv = p(x) \exp \lbrack \int p(x)\,dx \rbrack \)

This yields:
\(\displaystyle
g(x)\exp \lbrack \int p(x)\,dx \rbrack - \int g'(x) \exp \lbrack \int p(x)\,dx \rbrack dx
\)

Now (iv) becomes
\(\displaystyle
y = g(x) - \lgroup g(x)\exp \lbrack \int p(x)\,dx \rbrack - \int g'(x) \exp \lbrack \int p(x)\,dx \rbrack dx \rgroup \exp \lbrack - \int p(x)\,dx \rbrack
\)
Simplifying:
\(\displaystyle
y = \frac{\int g'(x)\exp \lbrack \int p(x)\,dx \rbrack dx}{\exp \lbrack \int p(x)\,dx \rbrack}
\)

Now the book defines
\(\displaystyle
\mu(x) = \exp \lbrack \int p(x)\,dx \rbrack
\)

Therefore, what I have is:
\(\displaystyle
y=\frac{\int \mu(x)g'(x)dx + c}{\mu(x)}
\)

Compare this to (iii) - you will see I have \(\displaystyle g'(x)\) instead of \(\displaystyle g(x)\).

So my question is: where did I go wrong. I've been looking over this for hours.

Thanks,
heaviside
 
  • #3
That's it!

I just went through it again, with the change you suggested, and with more care. And the solution came out.

Thank you Ackbach!
 
  • #4
heaviside said:
That's it!

I just went through it again, with the change you suggested, and with more care. And the solution came out.

Thank you Ackbach!

You're very welcome! Have a good one.
 
  • #5


Hello heaviside,

Thank you for reaching out for assistance with this ODE problem. From the steps that you have provided, it seems like you have approached the problem correctly. However, there may be a small error in the integration by parts that you have performed in the first step.

When integrating by parts, it is important to remember that the integral of a product is not simply the product of the integrals. In your first integration by parts, you have written:

\int udv = uv - \int vdu

However, the correct formula is:

\int udv = uv - \int vdu + C

Where C is the constant of integration. This may be the cause of the discrepancy between your answer and the one provided in the book.

I would suggest going through the integration by parts again, keeping in mind the constant of integration, and see if that leads to the correct solution. If you are still having trouble, you can also try using a different method such as substitution or the variation of parameters to solve the problem.

I hope this helps and good luck with your problem-solving!
 

FAQ: Assistance needed for this ODE problem

What is an ODE problem?

An ODE problem stands for ordinary differential equation problem. It is a type of mathematical problem that involves finding an unknown function that satisfies a given differential equation.

Why is assistance needed for this ODE problem?

ODE problems can be complex and require a deep understanding of mathematical concepts and techniques. Seeking assistance can help clarify any confusion and provide guidance on how to approach the problem.

What are some common techniques for solving ODE problems?

Some common techniques for solving ODE problems include separation of variables, substitution, and the use of integrating factors. It is important to understand the specific problem and choose the most suitable technique.

Can I use software to solve ODE problems?

Yes, there are many mathematical software programs available that can help solve ODE problems. However, it is important to have a good understanding of the problem and the techniques involved in order to use the software effectively.

How can I check if my solution to an ODE problem is correct?

One way to check if a solution to an ODE problem is correct is to substitute the solution into the original equation and see if it satisfies the equation. Additionally, you can compare your solution to known solutions or use numerical methods to verify the solution.

Similar threads

Replies
5
Views
1K
Replies
1
Views
1K
Replies
3
Views
3K
Replies
2
Views
2K
Replies
2
Views
1K
Replies
3
Views
2K
Replies
1
Views
1K
Replies
4
Views
1K
Back
Top