integer i, j, n double precision u(0:n+1,0:n+1), unew(0:n+1,0:n+1) do 10 j=1, n do 10 i=1, n unew(i,j) = $ 0.25*(u(i-1,j)+u(i,j+1)+u(i,j-1)+u(i+1,j)) - $ h * h * f(i,j) 10 continue