# Is there a need to specify $g$ as non-negative for $\int gd\nu=\int gfd\mu$ to hold?

Theorem. If $$\nu$$ has a density $$f$$ with respect to $$\mu$$, then $$\int gd\nu=\int gfd\mu$$ holds for non-negative $$g$$. Moreover, $$g$$ (not necessarily non-negative) is integrable with respect to $$\nu$$ if and only if $$gf$$ is integrable with respect to $$\mu$$, in which case both $$\int gd\nu=\int gfd\mu\qquad\text{and}\qquad \int_A gd\nu=\int_A gfd\mu$$ both hold. For non-negative $$g$$ $$\int_A gd\nu=\int_A gfd\mu$$ always holds.

Reference. Theorem 16.11 Pg 214 Probability & Measure, Patrick Billingsley

I am trying to understand why the special case of $$g$$ non-negative was mentioned separately. For any general $$g$$, both claims are true whenever either side is defined. Is there any relaxed assumption or additional property for the special case when $$g$$ is non-negative?

Note. I do not want a proof of the theorem. Once it is shown to be true for non-negative $$g$$, we can simply write any general $$g$$ as $$g=g^+-g^-$$.

Normally, if $$g$$ is non-negative and measurable (rather than integrable) then one allows $$\int g d\nu = +\infty$$, where this means that the set $$\{\int sd\nu: s \text{ a simple function}\}\subseteq \mathbb R$$ is unbounded. On the other hand, it is built into the definition of integrablity that $$\int |g|d\nu = \int g^++g^- d\nu < \infty.$$ Thus the equality for non-negative $$g$$ includes the assertion that $$\int g d\nu$$ is infinite if and only if $$\int gfd\mu$$ is infinite.