A curve passes through the origin and the slope of the tangent to the curve at any point \left(x_{1}\right) is equal to the sum of the coordinates of the point. Find the equation of the curve.
A curve passes through the origin and the slope of the tangent to the curve at any point \left(x_{1}\right) is equal to the sum of the coordinates of the point. Find the equation of the curve.

Solution:

General solution for the differential equation in the form of \frac{d y}{d x}+\mathrm{Py}= Qis given by,
y \cdot(I . F .)=\int Q \cdot(I . F .) d x+c
Where, integrating factor,
\text { I.F. }=e \int^{p d x}
The slope of the tangent to the curve =\mathrm{dy} / \mathrm{dx}
The slope of the tangent to the curve is equal to the sum of the coordinates of the point.
\frac{d y}{d x}=x+y( differential equation )
\frac{d y}{d x}-y=x \ldots \ldots \ldots(1)
In equation (1)
\mathrm{P}=-1 and \mathrm{Q}=\mathrm{x}
Therefore, integrating factor is
\text { I.F. }=e \int^{p} d x=\mathrm{e}^{j-1 \mathrm{dx}}=\mathrm{e}^{-\mathrm{x}}
General solution is
\begin{array}{r} y \cdot(I . F \cdot)=\int Q \cdot(I . F \cdot) d x+c \\ \text { y. }\left(e^{-x}\right)=\int(x) \cdot\left(e^{-x}\right) d x+c \ldots \ldots .(2) \end{array}
I=\int(x) \cdot\left(e^{-x}\right) d x
Let, u=x and v=e^{-x}
\begin{array}{l} \mathrm{I}=\mathrm{x} . \int e^{-x} d x-\int\left(\frac{d}{d x}(x) \cdot \int e^{-x} d x\right) d x \\ \mathrm{I}=-x \cdot e^{-x}-e^{-x} \end{array}
Substituting I in (2),
y \cdot\left(e^{-x}\right)=-x \cdot e^{-x}-e^{-x}+c
Dividing above equation by \mathrm{e}^{-\mathrm{x}},
\mathrm{y}=-x-1+c . e^{x} \text { (general solution) }
The curve passes through origin, therefore the above equation satisfies for x=0 and y=0
\mathrm{c}=1
Substituting c in general solution,
y+x+1=e^{x}