Topological invariants of magnetic fields, and the effect of reconnections | Synapse