If I take a basic example:

real[int] dims = [50,50];

border a(t=0, dims[0]){x=t; y=0; label=1;};

border b(t=0, dims[1]){x=dims[0]; y=t; label=2;};

border f(t=0, dims[0]){x=dims[0]-t; y=dims[1]; label=3;};

border d(t=0, dims[1]){x=0; y=dims[1]-t; label=4;};

border g(t=10, dims[0]-10){x=t; y=10; label=5;};

border h(t=10, dims[1]-10){x=dims[0]-10; y=t; label=6;};

border i(t=10, dims[0]-10){x=dims[0]-t; y=dims[1]-10; label=7;};

border j(t=10, dims[1]-10){x=10; y=dims[1]-t; label=8;};

int n=3;

mesh fm = buildmesh(a(n) + b(n) + f(n) + d(n) + g(-n) + h(-n) + i(-n) + j(-n));

plot(fm);

fespace Vh(fm, P1);

func real heatsource(){

return 0;

}

Vh u, v;

Vh myHeat = heatsource();

problem heat(u,v) = int2d(fm)(dx(u)*dx(v) + dy(u)*dy(v)) - int2d(fm)(myHeat*v)

+ on(1, u=0) + on(2, u=0) + on(3, u=0) + on(4, u=0) + on(5, u=0) + on(6, u=0)

+ on(7, u=10) + on(8, u=0);

heat;

plot(u, wait=true, fill=true, dim=2);

ofstream out (“map.txt” );

out.fixed;

for(int i=0; i<dims[0]; i++){

for(int j=0; j<dims[1]; j++){

out << u(i,j) << " ";

}

out << endl;

}

Then freefem display:

While matplotlib display:

It seems like some values are assigned inside the interior square, while not displayed by freefem