% PDE example from the lecture
clear all; close all;
level = 5;
[mass,grad,nodes,element,interior,centers,ncoord,nelem] = FEMdata(level);
a = ones(nelem,1);
A = UpdateStiffness(grad,a);
f = @(x) sum(x,2);
rhs = mass(interior,:)*f(nodes);
sol = zeros(ncoord,1);
sol(interior) = A(interior,interior)\rhs;
figure;
trisurf(element,nodes(:,1),nodes(:,2),sol);
