Transfer function in

Exact same problem and solution as in PETSc error of ChangeNumbering - #2 by prj.