Since we’ve seen that all contractible spaces have trivial de Rham cohomology, we can’t use that tool to tell them apart. Instead, we introduce de Rham cohomology with compact support. This is just like the regular version, except we only use differential forms with compact support. The space of compactly supported -forms on is ; closed and exact forms are denoted by and , respectively. And the cohomology groups themselves are .
To see that these are useful, we’ll start slowly and compute . Obviously, if is an -form on its exterior derivative must vanish, so . If , then we write for some compactly-supported -form . The support of both and is contained in some large -dimensional parallelepiped , so we can use Stokes’ theorem to write
I say that the converse is also true: if integrates to zero over all of — the integral is defined because is compactly supported — then for some compactly-supported . We’ll actually prove an equivalent statement; if is a connected open subset of containing the support of we pick some parallelepiped and an -form supported in with integral . If is any compactly supported -form with support in and integral , then for some compactly-supported . It should be clear that our assertion is a special case of this one.
To prove this, let be a sequence of parallelepipeds covering the support of . Another partition of unity argument tells us that it suffices to prove this statement within each of the , so we can assume that is supported within some parallelepiped . I say that we can connect to by a sequence of parallelepipeds contained in , each of which overlaps the next. This follows because the set of points in we can reach with such a sequence of parallelepipeds is open, as is the set of points we can’t; since is connected, only one of these can be nonempty, and since we can surely reach any point in , the set of points we can’t reach must be empty.
So now for each we can pick supported in the intersection of the th and st parallelepipeds and with integral . The difference is supported in the th parallelepiped and has integral ; since the parallelepiped is contractible, we can conclude that and differ by an exact form. Similarly, has integral , as does , so these also give us exact forms. And thus putting them all together we find that
is a finite linear combination of a bunch of exact -forms, and so it’s exact as well.
The upshot is that the map sending an -form to its integral over is a linear surjection whose kernel is exactly . This means that .