Constant of integration for solving differential equation

integrationordinary differential equations

As I am progressing differential equations practice, I found myself at somewhat of a roadblock. The roadblock is essentially that let's say we have the following equation:$$\int x^2\,dx=\int y\,dy.$$Now when we put the constants down after integration, such as:$$\frac{x^3}{3}+c_1=\frac{y^2}{2}+c_2,$$would $c_1$ and $c_2$ not have to have the same value? Of course, the problem then becomes that the constant would cancel out, and there would be no constant in the solution. However, I was just wondering why the constants could be different, especially since we need to ensure that both left and right antiderivatives are the same function?

In the case that the constants can be different, would someone be able to explain why that can be the case? Thanks so much.

Best Answer

As Sean mentioned in the comments... The constants are entirely determined by the initial conditions of your equation. Given your equation we have;

$${x^3\over3}+C_1={y^2\over2}+C_2 \implies {x^3\over3}+C_3={y^2\over2}$$

$$y=\bigg({2x^3\over3}+C_4\bigg)^{1\over 2}$$

Where $C_3=C_1-C_2$ and $C_4=2C_3$.

Now lets say that we were given the initial condition $y(0)=1$. That would yield...

$$y(0)=(C_4)^{1\over2}=1 \implies C_4=2C_3=2(C_1-C_2)=1$$

$$\therefore C_1-C_2={1\over2}$$

So $\textbf{any}$ 2 constants ($C_1$ and $C_2$) which satisfy that condition will give a legitimate solution to your equation with the given initial condition.

Related Question