If $\frac{d y}{d x}=e^{-2 y}$ and $y=0$ when $x=5$, then find the value of $x$ when $y=3$.
$$\begin{aligned} & \text { Given that, } \quad \frac{d y}{d x}=e^{-2 y} \Rightarrow \quad \frac{d y}{e^{-2 y}}=d x \\ & \Rightarrow \quad \int e^{2 y} d y=\int d x \Rightarrow \frac{e^{2 y}}{2}=x+C\quad\text{..... (i)} \end{aligned}$$
$$\begin{aligned} &\text { When } x=5 \text { and } y=0 \text {, then substituting these values in Eq. (i), we get }\\ &\begin{array}{l} & \frac{e^0}{2}=5+C \\ \Rightarrow & \frac{1}{2} =5+C \quad \Rightarrow \quad C=\frac{1}{2}-5=-\frac{9}{2} \\ \text { Eq. (i) becomes } & e^{2 y} =2 x-9 \\ \text { When } y=3 \text {, then } & e^6 =2 x-9 \Rightarrow 2 x=e^6+9 \\ \therefore & x =\frac{\left(e^6+9\right)}{2} \end{array} \end{aligned}$$
Solve $\left(x^2-1\right) \frac{d y}{d x}+2 x y=\frac{1}{x^2-1}$.
Given differential equation is
$$\left(x^2-1\right) \frac{d y}{d x}+2 x y=\frac{1}{x^2-1}$$
$\Rightarrow \quad \frac{d y}{d x}+\left(\frac{2 x}{x^2-1}\right) y=\frac{1}{\left(x^2-1\right)^2}$
which is a linear differential equation.
On comparing it with $\frac{d y}{d x}+P y=Q$, we get
$$\begin{aligned} P & =\frac{2 x}{x^2-1}, Q=\frac{1}{\left(x^2-1\right)^2} \\ \mathrm{IF} & =e^{\int P d x}=e^{\int\left(\frac{2 x}{x^2-1}\right)^{d x}} \\ \text{Put}\quad x^2-1 & =t \Rightarrow 2 x d x=d t \\ \therefore\quad\mathrm{IF} & =e^{\int \frac{d t}{t}}=e^{\log t}=t=\left(x^2-1\right) \end{aligned}$$
The complete solution is
$$\begin{aligned} y \cdot \mathrm{IF} & =\int Q \cdot \mathrm{IF}+K \\ \Rightarrow\quad y \cdot\left(x^2-1\right) & =\int \frac{1}{\left(x^2-1\right)^2} \cdot\left(x^2-1\right) d x+K \\ \Rightarrow\quad y \cdot\left(x^2-1\right) & =\int \frac{d x}{\left(x^2-1\right)}+K \\ \Rightarrow\quad y \cdot\left(x^2-1\right) & =\frac{1}{2} \log \left(\frac{x-1}{x+1}\right)+K \end{aligned}$$
Solve $\frac{d y}{d x}+2 x y=y.$
Given that, $$\frac{d y}{d x}+2 x y=y$$
$$\begin{aligned} &\begin{array}{ll} \Rightarrow & \frac{d y}{d x}+2 x y-y=0 \\ \Rightarrow & \frac{d y}{d x}+(2 x-1) y=0 \end{array}\\ &\text { which is a linear differential equation. } \end{aligned}$$
$$\begin{aligned} &\text { On comparing it with } \frac{d y}{d x}+P y=Q \text {, we get }\\ &\begin{aligned} P & =(2 x-1), Q=0 \\ \mathrm{IF} & =e^{\int P d x}=e^{\int(2 x-1) d x} \\ & =e^{\left(\frac{2 x^2}{2}-x\right)}=e^{x^2-x} \end{aligned} \end{aligned}$$
The complete solution is
$$\begin{array}{l} & y \cdot e^{x^2-x} =\int Q \cdot e^{x^2-x} d x+C \\ \Rightarrow & y \cdot e^{x^2-x} =0+C \\ \Rightarrow & y =C e^{x-x^2} \end{array}$$
Find the general solution of $\frac{d y}{d x}+a y=e^{m x}$.
Given differential equation is
$$\frac{d y}{d x}+a y=e^{m x}$$
which is a linear differential equation.
On comparing it with $\quad \frac{d y}{d x}+P y=Q$, we get
$$\begin{aligned} P & =a, Q=e^{m x} \\ \mathrm{IF} & =e^{\int P d x}=e^{\int a d x}=e^{a x} \end{aligned}$$
The general solution is $\quad y \cdot e^{a x}=\int e^{m x} \cdot e^{a x} d x+C$
$$\begin{array}{l} \Rightarrow & y \cdot e^{a x}=\int e^{(m+a) x} d x+C \\ \Rightarrow & y \cdot e^{a x}=\frac{e^{(m+a) x}}{(m+a)}+C \\ \Rightarrow & (m+a) y=\frac{e^{(m+a) x}}{e^{a x}}+\frac{(m+a) C}{e^{a x}} \\ \Rightarrow & (m+a) y=e^{m x}+K e^{-a x}\quad [\because K=(m+a) C] \end{array}$$
Solve the differential equation $\frac{d y}{d x}+1=e^{x+y}$.
Given differential equation is $\quad \frac{d y}{d x}+1=e^{x+y}\quad\text{.... (i)}$
On substituting $x+y=t$, we get
$$1+\frac{d y}{d x}=\frac{d t}{d x}$$
Eq. (i) becomes $$\frac{d t}{d x}=e^t$$
$$ \begin{array}{ll} \Rightarrow & e^{-t} d t=d x \\ \Rightarrow & -e^{-t}=x+C \\ \Rightarrow & \frac{-1}{e^{x+y}}=x+C \\ \Rightarrow & -1=(x+C) e^{x+y}\\ \Rightarrow & (x+C) e^{x+y}+1=0 \end{array}$$