something wrong
Hi, people.
I tested a poisson solver in 3D with an exact solution, first of all, I tested laplacian with f(x,y,z) = cos(pi x) cos(pi y) cos(pi z), and I used standard 7 points finite difference laplacian, and as a source term I used exact solution 3pi^2 cos(pi x) cos(pi y) cos(pi z) and I calculate the residual, but it is huge error. something like 29.00 even in 32 x 32 grid points, and my domain is unit cubic, and I imposed a Neumann boundary conditions. Do you have any idea about this situation? How should I implement at boundary to reduce this big errors. 
Re: something wrong
Why don't you start with the simpler Dirichlet BC, where you specify the BC exactly, say zero all around, without the approximations that Neumann brings into the table? So long as you have a source term this BC will be ok.
If you get a better convergence rate with DBC, then perhaps you need to use higher order approximations for the grads in the NBC or at least cluster the grids near the boundaries. If you still get bad results, then you have a bug! Adrin Gharakhani 
Re: something wrong
dear JunseokKim, i happened to solve a poisson eq. with neumann bc. please check if your poisson eq. if it satisfy the consequence of the Green theorem, failing to satisfy this theorem will cause problem in the numerical solution. if your eq. doesn't satisfy this theorem, you can modify the source term. please refer to the posting: convergent prob. in solving poisson eq(neumann BC) (118)  yf yap , Thu, 8 Feb 2001, 8:29 a.m. in this forum for more information on the matter. hope that it is helpful.

All times are GMT 4. The time now is 21:19. 