I attempted to parallellize it using
for j=2:n
parfor i=2:n
w(i,j)=0.25*(w_old(i-1,j)+w_old(i+1,j)+w_old(i,j-1)+w_old(i,j+1));
end
end
I started matlabpool, and run the function. The serial version works, but the parallel version fail to display any result at all. May I know if parfor loop is properly used in this case? If not, how should i change it?