m - number of local rows (or PETSC_DECIDE to have calculated if M is given) This value should be the same as the local size used in creating the y vector for the matrix-vector product y = Ax.
n - This value should be the same as the local size used in creating the x vector for the matrix-vector product y = Ax. (or PETSC_DECIDE to have calculated if N is given) For square matrices n is almost always m.
The user can set the error_rel via MatMFFDSetFunctionError() and umin via MatMFFDDSSetUmin(); see Users-Manual: ch_snes for details.
The user should call MatDestroy() when finished with the matrix-free matrix context.