Forum Message

 

 

We have moved the forum to https://forum.ngsolve.org . This is an archived version of the topics until 05/05/23. All the topics were moved to the new forum and conversations can be continued there. This forum is just kept as legacy to not invalidate old links. If you want to continue a conversation just look for the topic in the new forum.

Notice

The forum is in read only mode.

fast preconditioners

More
4 years 1 month ago #2464 by gcdiwan
fast preconditioners was created by gcdiwan
Dear NGSolve Developers;
Code:
prec = Preconditioner(a, type="bddc", inverse='sparsecholesky')

seems very slow as the build+solve time is equivalent to solving with sparsecholesky directly. Are there other approximate inverses available (or under consideration) such as ILU or ILUT?

Thanks in advance!
More
4 years 1 month ago - 4 years 1 month ago #2465 by lkogler
Replied by lkogler on topic fast preconditioners
Our bddc preconditioner is just a way to reduce a high order problem to the low order case. For low order systems, bddc is the direct inverse.

If you are using static condensation (eliminate_internal), many of the high order DOFs are alreade eliminated, so the difference between bddc and direct inverse is smaller.

Besides that, if you are running with a TaskManager, bddc can be very slow if you also have additional shared memory parallelization from your LAPACK library.
For MKL, set MKL_THREADING_LAYER to SEQUENTIAL.
For OpenBlas, set OPENBLAS_NUM_THREADS to 1

If you want to try out ILU or ILUT, those are, I believe, available through the PETSc interface. PETSc does not have any shared memory parallelization, however, so take that in mind.

Finally, the built-in sparsecholesky is very fast, it is really hard to beat except for smaller or medium problems.

Best,
Lukas
Last edit: 4 years 1 month ago by lkogler.
More
4 years 1 month ago #2466 by gcdiwan
Replied by gcdiwan on topic fast preconditioners

lkogler wrote:
If you want to try out ILU or ILUT, those are, I believe, available through the PETSc interface. PETSc does not have any shared memory parallelization, however, so take that in mind.

Finally, the built-in sparsecholesky is very fast, it is really hard to beat except for smaller or medium problems.

Best,
Lukas


Hi Lukas,

Thanks for your reply. In relation to your comment on sparsecholesky, i thought it works only on local matrices and not on parallel matrices (see my earlier post: ngsolve.org/forum/ngspy-forum/1031-sigse...roblems?start=6#2435 ). What do you mean by large in relation to sparsecholesky? I am envisaging to solve problems of size 2-10 million dofs and possibly ill-conditioned.
More
4 years 1 month ago - 4 years 1 month ago #2468 by lkogler
Replied by lkogler on topic fast preconditioners
It does, but is works shared memory parallel.

Strike the "except" from my comment. I was thinking maybe at most 10^5 DOFs or so. In that range it should be very fast compared to other options.

Direct solvers care about bad condition numbers much, much less than preconditioners.
Last edit: 4 years 1 month ago by lkogler.
Time to create page: 0.139 seconds