Just consider a simple problem:

[Homogeneous Helmholtz Dirichlet BC]

in , means unit disk.

on [Not true, should be ].

If I use ‘finite element method’, to make our problem easier to handle, I choose square as our domain.

Then , one can use Jacobi, Gauss Seidel, SOR, SSOR, with or without preconditioner and shift. However, I found for this very problem, the result doesn’t converge to my exact solution, in other word, there is some error which cannot be cancelled through shrinking our step length.

%Jacobi

%U_now(i,j)=(U_prev(i-1,j)+U_prev(i+1,j)+U_prev(i,j+1)+U_prev(i,j-1))/(4-h*h*k*k);

%9 point

%U_now(i,j)=((2/3)*(U_prev(i-1,j)+U_prev(i+1,j)+U_prev(i,j-1)+U_prev(i,j+1))+(1/6)*(U_prev(i-1,j-1)+U_prev(i-1,j+1)+U_prev(i+1,j-1)+U_prev(i+1,j+1)))/(10/3-k*k*h*h);

%Gauss Seidel

U_now(i,j)=(U_now(i-1,j)+U_prev(i+1,j)+U_now(i,j-1)+U_prev(i,j+1))/(4-h*h*k*k);

%SOR

% U_now(i,j)=(1-omega)*U_prev(i,j)+omega*(U_now(i-1,j)+U_prev(i+1,j)+U_now(i,j-1)+U_prev(i,j+1))/(4-h*h*k*k);

By using package ‘distmesh’, I construct the PI-FEM for the original problem. Still I have encountered the same problem. The linear system is not large but sparse, so GMRES can easily solve it. I used the preconditioner , where is Bessel function of .

This is the result at , even I put the size of uniform triangle , the error stills remain unchanged around some small number.

I have some idea about why FEM cannot give a good result when is LARGE, I know the estimate of error is .

However, matlab ‘pdetool’ toolbox can solve this very easily……[not true : )]

Update: Now solved…with error order of 2.

0.000000
0.000000

### Like this:

Like Loading...

Ooooooooooooooooooops, Matlab pdetool toolbox also sucks. What a relief!

I am a such idiot! I made a mistake on mass matrix by using 1/12. Now the problem almost solved, and the BC is totally wrong…..dismiss it.