General solution formula of a differential equation

Click For Summary
SUMMARY

The general solution formula for the differential equation y' + P(x)y = G(x) is given by y(x) = e^{-\int P(x)dx}[C + \int e^{\int P(x)dx}G(x)dx]. For the specific case of y' + xy = x, the solution simplifies to y = Ce^{-\frac{x^2}{2}} + 1. An alternative approach leads to the solution y = 1 - Ce^{\frac{x^2}{2}} or y = 1 + Ce^{\frac{x^2}{2}}. The discrepancy between the two solutions arises from a sign error during integration, specifically when integrating 1/(1-y).

PREREQUISITES
  • Understanding of first-order differential equations
  • Familiarity with integration techniques
  • Knowledge of exponential functions and their properties
  • Basic grasp of the method of integrating factors
NEXT STEPS
  • Study the method of integrating factors for solving linear differential equations
  • Learn about the implications of initial conditions on the general solution
  • Explore the concept of uniqueness in solutions of differential equations
  • Investigate the application of l'Hôpital's rule in solving limits related to differential equations
USEFUL FOR

Students and professionals in mathematics, particularly those focusing on differential equations, as well as educators looking to clarify solution methods and common pitfalls in integration.

coki2000
Messages
91
Reaction score
0
Hello,

The general solution of a differential equation for y'+P(x)y=G(x) is

y(x)=e^{-\int P(x)dx}[C+\int e^{\int P(x)dx}G(x)dx]

for y'+xy=x

y(x)=e^{-\int xdx}[C+\int e^{\int xdx}xdx] i have

y=Ce^{-\frac{x^2}{2}}+1

By the other solution

\frac{dy}{dx}+xy=x \rightarrow \frac{dy}{dx}=x(1-y)\Rightarrow \frac{dy}{1-y}=xdx

integrating the both sides

\int \frac{dy}{1-y}=\int xdx\Rightarrow \ln \left|1-y \right|=\frac{x^2}{2}+C<br /> <br /> \left|1-y \right|=Ce^{\frac{x^2}{2}}\Rightarrow y=1-Ce^{\frac{x^2}{2}} or y=1+Ce^{\frac{x^2}{2}}

Why the two solutions are different and where is my mistake?Please help me.Thanks.
 
Physics news on Phys.org
when you integrate 1/(1-y), you forgot the negative. It should be - ln (1- y).
 
l'Hôpital said:
when you integrate 1/(1-y), you forgot the negative. It should be - ln (1- y).
ohh thanks l'Hopital:blushing:
 

Similar threads

  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 3 ·
Replies
3
Views
3K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 14 ·
Replies
14
Views
2K
  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 2 ·
Replies
2
Views
1K
  • · Replies 2 ·
Replies
2
Views
1K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 6 ·
Replies
6
Views
2K
  • · Replies 3 ·
Replies
3
Views
3K