Limsup is defined similarly. The limsup is the limit, as m approaches infinity, of the supremum of fn for n ≥ m. As m marches along, the supremum can only decrease.
Now for Fatou's lemma. (biography) The integral of liminf of fn ≤ liminf of ∫ fn. This assumes each fn is nonnegative and measurable.
Let tn be the infimum of fk, for all k ≥ n. Thus liminf of fn is the limit of tn. We already said tn is monotonically increasing. Clearly tn is nonnegative. Let's prove tn is measurable.
Start with fn, which is measurable. Note that min(fn,fn+1) is measurable. By induction, the minimum of fn through fk is measurable. These functions are monotonically decreasing, and tn is the limit as k approaches infinity. Since the limit is measurable, tn is measurable.
Again, liminf(fn) is the limit of tn. By the monotone convergence theorem, the integral of liminf(fn) is the limit of the integrals of tn. Since these integrals are increasing, the limit of the integrals of tn equals the liminf of the integrals of tn. Across all of X, fn is at least as large as tn. Thus ∫ tn ≤ ∫ fn. Apply the liminf operator, and each infimum is at least as large, whence the resulting limit is at least as large. Therefore, ∫ liminf(fn) ≤ liminf of ∫ fn.
If the functions can be bounded by a measurable function with a finite integral, a similar result holds in the opposite direction. The proof is the same as above, but we use the supremum instead of the infimum, and then invoke the reverse monotone convergence theorem.
∫ limsup(fn) ≥ limsup ∫ fn
Fix an x, and assume f(x) = ∞. For any large positive value b, there is some n such that fn, and values beyond fn, are above b. This puts sn and tn above b. Thus s and t approach infinity, just like f. A similar result holds for -∞.
Assume f(x) = b, where b is finite. With t increasing, and s decreasing, the limits exist. With s ≥ t, the limit of s is at least the limit of t. Suppose s remains above b+ε infinitely often. Move out in the sequence, so that fn and beyond are all within ε of b. This places sn within ε of b. This is a contradiction, hence the limit of s is at least b. Similarly, the limit of t is at most b. Put this all together and the limit of sn = the limit of tn = the limit of fn = b = f(x).
Concentrate on the sequence tn, which is measurable and increasing. We already showed that the limit is measurable, hence f is a measurable function.
This may remind you of trapping a riemann sum between a lower sum and an upper sum.
Let's see what goes wrong when g does not exist. Let X be the open interval (0,1), and let lebesgue integration reflect riemann integration. Let fn be the step function that is n from 0 to 1/n, and 0 elsewhere. Each fn has integral 1, and the limit is of course 1. Yet the limit function f is identically 0, hence its integral is 0.