CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > General Forums > Main CFD Forum

are the cg or bicgstab method suitable for dense

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   September 1, 2008, 08:48
Default are the cg or bicgstab method suitable for dense
  #1
ztdep
Guest
 
Posts: n/a
dear friends: are the cg or bicgstab method suitable for dense matrix.

  Reply With Quote

Old   September 1, 2008, 21:25
Default Re: are the cg or bicgstab method suitable for den
  #2
solver-issues
Guest
 
Posts: n/a
i think you can use it there, but the problem would be of creating preconditioner.

  Reply With Quote

Old   September 1, 2008, 22:20
Default Re: are the cg or bicgstab method suitable for den
  #3
ztdep
Guest
 
Posts: n/a
thank you very much for you answer, i want to use a simpel diagonal precontioner

  Reply With Quote

Old   September 1, 2008, 22:35
Default Re: are the cg or bicgstab method suitable for den
  #4
solver-issues
Guest
 
Posts: n/a
diagonal preconditioner is not very good, you could use Gauss Seidel as preconditioner it would be much better.

  Reply With Quote

Old   September 2, 2008, 00:57
Default Re: are the cg or bicgstab method suitable for den
  #5
Ted
Guest
 
Posts: n/a
no, iterative solver r not good selection.

note that theoritically a cg solver (for SPD matrix) can converge after n interation, and number of FLOPs within each iteration is porportional to number of non-zeros, in a dense matrix it is n^2 (is feasible for sparse solver)

so ur total FLOPs is ~ n^3

for a direct solver this factor is ~ n^3

as direct solver is more rubost, it is a more feasible selection.

e.g., LU decoposition

  Reply With Quote

Old   September 2, 2008, 05:24
Default Re: are the cg or bicgstab method suitable for den
  #6
Jed
Guest
 
Posts: n/a
If your dense matrix is extremely well conditioned, then a Krylov method might be okay, otherwise a direct method is definitely the way to go.

May I ask *why* you have a dense matrix. Frequently there is a way to avoid it (and there must be if you want any sort of scalability).
  Reply With Quote

Old   September 6, 2008, 07:02
Default Re: are the cg or bicgstab method suitable for den
  #7
ztdep
Guest
 
Posts: n/a
the dense matrix come from the DQ method. by the way, do you know where to download a free LU decomposition code regards
  Reply With Quote

Old   September 6, 2008, 09:04
Default Re: are the cg or bicgstab method suitable for den
  #8
Jed
Guest
 
Posts: n/a
Do you want parallel? If so, use PETSc (or PLAPACK if you're sure that's all you need). Otherwise, what's wrong with Lapack?

I'm not familiar with DQ, but it looks like a pseudospectral method. It also looks like there are versions that produce sparse matrices. Does your matrix have tensor/Kronecker product structure? If so, you can apply the matrix using that structure and solve using a Krylov method. You'll need a preconditioner, but you can probably assemble one based on a low-order finite element/difference scheme so that it will be spectrally equivalent but very sparse.

For instance, I have a code that solves a global spectral inhomogeneous 3D Stokes problem with 3.5 million degrees of freedom in a few minutes on a single processor. If I formed the matrix, it would be dense so would require 100 TiB of memory, but I can apply it matrix-free for cheap and precondition with a very sparse matrix.
  Reply With Quote

Old   September 6, 2008, 09:41
Default Re: are the cg or bicgstab method suitable for den
  #9
Ted
Guest
 
Posts: n/a
dense lu decompos is very simple, numerical recipe book include it, also you can see this:

http://www.cfd-online.com/Wiki/LU_decomposition http://en.wikipedia.org/wiki/LU_decomposition

if your matrix has some zero, you can explote its structure to improve performance, e.g. by reordering and using sparse direct solvers (e.g. UMFPACK or HSL sobroutines)

what is dimension of your matrix?

assuming n*n matrix, for n>10^4 direct solver is somehow impossible (memory CPU, memory scale by n^2 and CPU sclae by n^3)!
  Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
mass flow in is not equal to mass flow out saii CFX 12 March 19, 2018 05:21
[Gmsh] discretizer - gmshToFoam Andyjoe OpenFOAM Meshing & Mesh Conversion 13 March 14, 2012 04:35
Constant velocity of the material Sas CFX 15 July 13, 2010 08:56
Code for most powerfull FDV Method D.S.Nasan Main CFD Forum 6 September 4, 2008 02:08
Is SIMPLEC method suitable for turbomachinery? lhb Main CFD Forum 14 February 15, 2001 19:59


All times are GMT -4. The time now is 06:46.