# 1st order differential linear equation, question on absolute value

I'm trying to find the general solution to this equation: $$x \frac{dy}{dx}+3(y+x^2)=\frac{\sin(x)}{x}$$ Standard form puts it like this: $$\frac{dy}{dx}+\frac{3}{x}y=\frac{\sin(x)-3x^3}{x^2}$$ To determine the integrating factor I did $$e^{\int{3/x}\,dx}$$ and got $$e^{\ln{\lvert x\rvert}^3}$$.

Does this not simplify to $$\lvert x\rvert^3$$? In all the online calculators I've used, they've ignored the absolute value? The problem would be much easier if that was the case but I'm not convinced.

I wouldn't know how to integrate the following with the absolute value: $$\int{\frac{\lvert x\rvert^3}{x^2}\cdot (\sin(x)- 3x^3)\,dx}$$ I'd appreciate any help.

• For the sake of continuity of $\ln$ function, I prefer to assume $x>0$. – Sujit Bhattacharyya Mar 4 at 5:46
• The general solution is $C|x|^3$, but for an integrating factor you only need one solution, so $x^3$ will do. Try it out for $-x^3$, you'll get the same result regardless. – Dylan Mar 4 at 7:43

## 1 Answer

Hint

You can get rid of the problem if you start using $$y=\frac z {x^3}$$ which makes the equations to become $$z'=x \sin(x)-3x^4$$