# Dominated convergence with $g$ depending on $n$

I have a question about dominated convergence. Suppose I have a functions $f_n(x)$ which converge pointwise to $f(x)$. Furthermore, I know that $|f_n(x)|\leq g_n(x)$ for all $n$ and $x$, where $g_n(x)$ has limit $g(x)$. If I also know that $$\lim_{n\to\infty}\int g_n(x)dx=\int g(x)dx,$$ can I conclude that $$\lim_{n\to\infty}\int f_n(x)dx=\int f(x)dx?$$

(This is basically the dominated convergence theorem, with $g$ replaced by $g_n$.)

Yes, that's the General Lebesgue Dominated Convergence Theorem except you give the additional assumption that $\lim g_n$ exists: Let $\{f_n\}_{n\in\mathbb{N}}$ be a sequence of $\mu$-measurable functions $f_n:(E,\mathcal{E},\mu)\to \bar{\mathbb{R}}$. Suppose $f_n\to f$, point-wise a.e. on $E$ and there is a sequence $\{g_n\}_{n\in\mathbb{N}}$ of $\mu$-integrable functions that converge pointwise a.e. to $g$ and
$$|f_n| \leq g_n$$ for all $n \in \mathbb{N}$.
If $\int_E g_n \to \int_E g$, then $\int_E f_n \to \int_E f$.