Why is $\int \frac{f'(x)}{f(x)}=\ln |f(x)|$ ignored in differential equations? I've noticed that whenever $\int \frac{f'(x)}{f(x)}$ comes up in a differential equation the answer is always given as $\ln f(x)$ rather than $\ln |f(x)|$ as I was taught it should be. Is it because of the arbitrary constant? In other words, since $$\int \frac{f'(x)}{f(x)}=\ln |f(x)|+\ln A$$ for some constant $A$, then the answer is $\ln A|f(x)|$ and because $A$ can be positive or negative it follows that there is no point including the absolute signs? Hence the answer is given as $\ln f(x)+C$ for some constant $C$ rather than $\ln |f(x)|+C$. Is this why?
Review of Integrating Factors

Consider integrating factors in the context of linear equations, say $\dfrac{\mathrm{d}y}{\mathrm{d}t}+p\left(t\right)y=g\left(t\right)$. (I'll often drop the input $t$s from now on.) Our hope is to multiply the equation by some function $\mu$ to turn the left side into the derivative of a product, say $\left(\mu y\right)'$, so that we can integrate both sides and divide by $\mu$ to solve for $y$. Note that by the product rule, we have $\left(\mu y\right)'=\mu'y+\mu y'$. To get $\left(\mu y\right)'=\mu*\left(y'+py\right)$, we should look for $\mu$ that satisfy $\mu'=\mu p$. (That's a separable equation.)



Absolute values in integrating factors mostly don't matter

Note that if $\mu\left(t\right)$ is a valid integrating factor (in the sense that $\mu'\left(t\right)=\mu\left(t\right)p\left(t\right))$, then define $\nu(t)=-\mu(t)$ and note that $\nu'\left(t\right)=-\mu'\left(t\right)=-\mu\left(t\right)p\left(t\right)=\nu\left(t\right)p\left(t\right)$. But $\nu'=\nu p$ is exactly the equation $\nu$ should satisfy to be an integrating factor! So the negative of an integrating factor works just as well.

Now suppose you solve $\mu'=\mu p$ and get a solution like $\mu\left(t\right)=\left|\omega\left(t\right)\right|$, thanks to an integral of $\dfrac{\omega'\left(t\right)}{\omega\left(t\right)}$. On an interval where $\omega\left(t\right)$ is always nonnegative, $\mu\left(t\right)=\omega\left(t\right)$, and you don't need the absolute value. On an interval where $\omega\left(t\right)$ is always nonpositive, $\mu\left(t\right)=-\omega\left(t\right)$, so $\nu\left(t\right)=-\mu\left(t\right)=-\left(-\omega\left(t\right)\right)=\omega\left(t\right)$, and you still don't need to worry about the absolute value, since $\nu$ works fine, too.

Therefore, if you ignore the absolute value, you get valid solutions on these intervals where $\omega$ doesn't change sign.



In practice, absolute values in integrating factors don't matter at all

A limitation of the above discussion is that there's no guarantee the solutions on separate intervals will be able to connect up when $\omega\left(t\right)=0$. However, that's okay, because in practice an issue like that would usually arise because the original differential equation has a problem at that point. 

For example, with something like $ty'+3y=te^{t}$, you would rewrite as $y'+\dfrac{3}{t}y=e^{t}$ and initially get an integrating factor of $\left|t\right|^{3}$. By the above argument, for positive $t$ or negative $t$, you can get away with $t^{3}$ and learn that $t^{3}y=\int_{0}^{t}e^{x}\,\mathrm{dx}+C$. But what about at $t=0$? Well, that would make $t^3y$ not tell you about $y$, it would make $\dfrac{3}{t}$ undefined, and would make $ty'+3y=te^{t}$ not tell you anything about $y'$. In fact, the solutions for positive or negative $t$ diverge as $t$ approaches $0$, so you had no hope of finding a solution on an interval like $\left[-1,1\right]$ anyway.
Mathematicians doing ODE usually assume complex number calculations.  In that setting, the assertion
$$
\int\frac{dx}{x} = \log |x| + C
\tag{1}$$
is simply wrong.  $\log |x|$ is not complex differentiable at any point.  In particular, it does not have derivative $1/x$.  

But, as you note, you can still write
$$
\int \frac{dx}{x} = \log x + C
\tag{2}$$
even when $x&lt;0$.  The $\log$ and the $C$ may both be non-real complex numbers.  But only beginners would worry about that.  

I think formulas of the type (1) were invented by textbook writers within the last 50 years or so.