TITLE: Integration of a cohomology class over a homology class.
QUESTION [5 upvotes]: Can anyone explain to me what it is said in the following article : http://indico.ictp.it/event/a06114/material/0/0.pdf , page : $3$, by Mr. Aroldo Kaplan :
The paragraph says :

Stokes :
  $$ \int_M d \omega = \int_{ \partial M }\omega $$
  implies :
  $$ d \omega = 0 \ \ \Longleftrightarrow \ \ \int_{ \mathrm{boundary} } \omega = 0 \ \ \ \ \ \ \ \ \  \mathrm{and} \ \ \ \ \ \ \ \ \partial M = 0 \ \ \Longleftrightarrow \ \ \int_M \mathrm{exact} = 0 $$
  so, defining :
$ H^k ( X ) = \dfrac{ \{ \omega \in \bigwedge^k \ : \ d \omega = 0 \} }{ \{ \omega \in \bigwedge^{k} \ : \ \omega = d \phi \} } = \dfrac{ \mathrm{closed} }{ \mathrm{exact} } $ , $ \ H_k ( X ) = \dfrac{ \{ M \subset X \ : \ \partial M = 0 \} }{ \{ M \subset X \ : \ M = \partial N \} } = \dfrac{ \mathrm{cycles} }{ \mathrm{boundaries} } $
the bilinear (function?):
  $$ H^k ( X ) \times H_k ( X ) \to \mathbb{R}, \ \ \ \ \ \ \ \ \ \ \ \  ( [ \omega ] , [M] ) = \int_M \omega $$
  ( = flux of $ \omega $ through $ M $ ) is well defined.

So, I still do not understand why:
$$ H^k ( X ) \times H_k ( X ) \to \mathbb{R}, \ \ \ \ \ \ \ \ \ \ \ \  ( [ \omega ] , [M] ) = \int_M \omega $$
is well defined.
Can you explain to me that please ?
Thanks in advance for your help.

REPLY [2 votes]: let's prove that $([\omega],[M])=([\omega+d\phi],[M])$. 
indeed, $([\omega+d\phi],[M])-([\omega],[M])=\int_M d\phi=\int_{\partial M}\phi=0$, because $M$ is a cycle.
secondly, let's prove that $([\omega],[M])=([\omega],[M+\partial N])$.
indeed, $([\omega],[M+\partial N])-([\omega],[M])=\int_{\partial N}\omega=\int_N d\omega=0$, because $\omega$ is closed.