Finding the area enclosed by two curves when are areas under the x axis.

When finding the area enclosed by two curves,and are areas under the x axis. why don't I separate the areas above and below the x-axis for each curve, add them together, then take away the area under the curve for the other graph?

I'm asking because my textbook says you can just put everything into one expression,

$\int _a^bf\left(x\right)-g\left(x\right)dx\:$

but this doesn't make sense to me - I just can't visualise why.

• That only works if $f$ and $g$ never cross or you’re looking for a signed area. – amd Aug 3 '18 at 1:11
• I get that it works when looking for a signed (overlapping) area between two curves, but if part of a curve had a negative area, wouldn't it end up reducing the size of the final answer? Because we aren't accounting for areas under the x-axis by splitting the area under the curve into two, right? – Chx Aug 3 '18 at 1:18
• As long as $f(x)\ge g(x)$, then $f(x)-g(x)\ge0$. It doesn’t matter if the value of either function individually goes negative. Effectively, you’re computing the area under the curve of a new function $h(x)=f(x)-g(x)\ge0$. – amd Aug 3 '18 at 1:20