Hi,
I want to assemble a restriction matrix to extract the DoFs on part of the boundary.
I know the interpolate function can assemble such matrix by providing two FE function spaces. Can we define a P1 function space on one side of the unit square? then interpolate it to the P1 function space on the unit square?
see attached code.
Best regards,
Shihua
// Mesh
mesh Th = square(4, 4);
plot(Th, wait=true);
// Fespace
fespace Vh(Th, P1);
// Fespace on one edge of unit square
meshL Eh=segment(4); //
fespace EVh(Eh , P1);
// interpolate matrix from
matrix Rt;
Rt = interpolate(Vh,EVh,inside=true);