  We are interested in the numerical reconstruction of a vector field with
prescribed divergence and curl in a general domain of R 3 or R 2 , not
necessarily contractible. To this aim, we introduce some basic concepts of
finite element exterieur calculus and rely heavily on recent results of P.
Leopardi and A. Stern. The goal of the paper is to take advantage of the links
between usual vector calculus and exterior calculus and show the interest of
the exterior calculus framework, without too much prior knowledge of the
subject. We start by describing the method used for contractible domains and
its implementation using the FEniCS library (see fenicsproject.org). We then
address the problems encountered with non contractible domains and general
boundary conditions and explain how to adapt the method to handle these cases.
Finally we give some numerical results obtained with this method, in dimension
2 and 3.
