# Integrating both sides of an equation with respect to what?

Let's say we have the following DE:

$$\frac{dy}{dx} = x$$

1. That's how It could be solved:

$$dy = x dx$$

$$\int{dy}=\int{xdx}$$

$$y=\frac{1}{2}x^2+c$$

Is it mathematically correct to separate $$dy$$ and $$dx$$ ? Or it would appear as the derivative of $$y$$ with respect to $$x$$ is a fraction which is not true.

2. Another method of writing the solution can be:

$$\int\frac{dy}{dx} dx=\int{xdx}$$

$$\int{dy}=\int{xdx}$$

$$y=\frac{1}{2}x^2+c$$

That's integrating the DE with respect to x. Is this mathematically correct? It seems like the $$dx$$ cancels each other in the LHS, but we are not allowed to treat this as a fraction.

My Questions are:

• Which of these ways of writing the solution is the most accurate?
• And which of these 2 is wrong in terms of following mathematical structure?
• When we integrate both sides of the equation, can we just put the integral sign without integrating with respect to a variable? (for example in case 1)
• Third method should be $\int y'\,dx.$ If you made that change, all three methods are equally valid. Oct 1, 2019 at 17:12
• It is probably more correct to write $\int {dy(x) \over dx} dx = \int x dx$... Oct 1, 2019 at 17:16
• To justify the first method in full rigor, one needs to develop the theory of differential forms. But the upshot is that, all the manipulations in your solution can be validated. Oct 1, 2019 at 17:25
• The integral sign is very important as it defines the integration. It also tells us if it indefinite or definite.
– Sam
Oct 1, 2019 at 18:00
• Oct 2, 2019 at 4:03

The third is wrong. $$\int y'dy \ne y$$, since $$y'\ne 1$$.
It is separable equation where $$y= y(x)$$. Consider the problem $$\frac{dy}{dx}=F(x)*Q(y)$$ where $$F(x)$$ depends only of $$x$$ and $$Q(y)$$ only of $$y$$. If $$Q(y) \neq 0$$ we can rewrite this as $$\frac{y'(x)}{Q(y(x))}= F(x)$$ $$\int_{x_0}^x{\frac{y'(t)}{Q(y(t))}dt}=\int_{x_0}^x{F(t)dt}$$ Then $$y(t)=s$$ We will get $$\int_{y(x_0)}^{y(x)}{\frac{ds}{Q(s)}} = \int_{x_0}^x{F(t)dx}$$
When your diffferential equation is separable you end up with a differential form $$f(y)dy = g(x) dx$$
Since you are assuming taht $$y=y(x)$$ you may integrate both sides with respect to $$x$$ but the LHS has gone through a change of variable so we get $$\int f(y(x))y'(x)dx = \int f(y)dy = \int g(x) dx$$