  In this article, using an exemplar-based approach, we investigate the
inpainting problem, introducing a new mathematical functional, whose
minimization determines the quality of the reconstructions. The new functional
expression takes into account of fnite differences terms, in a similar fashion
to what happens in the theoretical Sobolev spaces. Moreover, we introduce a new
priority index to determine the scanning order of the points to inpaint,
prioritizing the uncertainty reduction in the choice. The achieved results
highlight important theoretical-connected aspects of the inpainting by patch
procedure.
