Catch elem_id as a dof_id_type.
Catch values from Petsc as PetscInts.