Help about the preconditioner in gmres method
Hi, all, I am importing a implicit time method to my 3D NS finite difference code. I used the Matrixfree method to get the Jaccobi matrixvector product, and the sparse linear equations are solved by gmres method. Now I am in trouble in constructing a preconditioner for my finite difference code. I hope the preconditioning method is similar with the matrixfree method, that means only the preconditionervector product needed. I hope someone can suggest me how to construct a preconditioner for my finite difference code. I read some papers about how to get the preconditioner for finite volume method. But I can not understand it and import them to the finite difference method. I don't know I describe the question clearly. I am poor in English. Thanks for your any help in advance .

Re: Help about the preconditioner in gmres method
It's not quite the same. You need to write a subroutine that calculates (approximately) an estimate of the increment for Newton's method. One choice is to use something like the SIMPLE algorithm but rearranged to yield the "correct" increments. Knolls & Keyes (correct spelling?) have written papers on this. One possible choice, which would avoid the need to construct the preconditioner, would be to wrap a multigrid solver around around the call to GMRES.

Re: Help about the preconditioner in gmres method
I also recommend Knoll & Keyes 2004. Let's suppose we are doing left preconditioning so we would like P^{1} A to be approximately the identity. The trouble is that P^{1} usually needs to be dense. Storing a dense matrix is not going to work and unless you have a fast solver for a similar problem (which generally requires a really nice domain) then you you'll want to actually form a preconditioning matrix P because preconditioners (such as ILU(k), AMG, DD) normally want matrix entries. The big win is that the preconditioning matrix can come from simpler physics and/or lower order discretization so it may have fewer entries and be easier to compute than the full Jacobian. Also, the preconditioner can often be lagged (don't recompute the preconditioner every Newton step) which further reduces assembly cost. When you do have a fast solver for simpler physics, then by all means, try it. This is called `physics based preconditioning' in Knoll & Keyes.
Note that linear multigrid as a preconditioner for a Krylov method is generally faster than nonlinear multigrid. 
Re: Help about the preconditioner in gmres method
Thank Tom and Jed for your help. I will try it.

All times are GMT 4. The time now is 11:57. 