Now I have another question. I am trying to compute the L2 error over all the faces. For simplicity, I tested this starting from the tutorial step-51. I added another VectorTools::integrate_difference statement to the postprocess routine, with arguments dof_handler and solution (these correspond to the solution on the faces). However, this gives me an exception saying that some number is not finite (see error log in attachment). Is it even possible to compute errors on faces (and not cells) using VectorTools::integrate_difference? Or is there some other way to do it?
Well, from the documentation [2] the relevant part is "Compute the cellwise error of the finite element solution [...]". Indeed, VectorTools::integrate_difference doesn't consider face integrals. However, you can just write such a function with not too much effort if you already use face loops in your cod:
Basically, just evaluate your reference function on the respective face in the quadrature points using Function::[vector_]value/gradient[_list] depending on the number of components your solution has and the norm you are interested in. Then, you compute the respective values for your solution using FEValues::get_function_values/gradients, compute the squared difference (for L^2 or H^1), multiply with FEValues::JxW and add everything up.