PETSc error of ChangeNumbering

Hi,

I am working on 3D Navier Stokes equations. I use Newton’s method. We met an error when executing ChangeNumbering from Freefem to PETSc:

Assertion fail : (ptIn->N() == ptA->_A->getDof())
	line :2946, in file PETSc-code.hpp

I am not sure what happened here. Could you help me out? I attach the code here.
ns_3d.edp (3.4 KB)
05.mesh.zip (7.8 MB)

Thank you!

You need to call buildDmesh() before you define your local fespace named SpaceVector.

Hi prj,

Thank you so much! It is resolved!