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

Is there any efficient algorithm to compute the determinant of a sparse matrix?

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   July 19, 2012, 16:42
Default Is there any efficient algorithm to compute the determinant of a sparse matrix?
  #1
Senior Member
 
Hector Redal
Join Date: Aug 2010
Location: Madrid, Spain
Posts: 243
Rep Power: 17
HectorRedal is on a distinguished road
Hello,

I would like to know if there is any efficient way to compute the determinant of an sparse matrix?

Kind regards,
Hector.
HectorRedal is offline   Reply With Quote

Old   July 20, 2012, 01:36
Default
  #2
Senior Member
 
ztdep's Avatar
 
p ding
Join Date: Mar 2009
Posts: 427
Rep Power: 19
ztdep is on a distinguished road
Send a message via Yahoo to ztdep Send a message via Skype™ to ztdep
LU decomposition for the sparse decomposition. the determinant can be abtained by sum the digonal of mattrix.
ztdep is offline   Reply With Quote

Old   July 20, 2012, 07:35
Default
  #3
Senior Member
 
Hector Redal
Join Date: Aug 2010
Location: Madrid, Spain
Posts: 243
Rep Power: 17
HectorRedal is on a distinguished road
Quote:
Originally Posted by ztdep View Post
LU decomposition for the sparse decomposition. the determinant can be abtained by sum the digonal of mattrix.
Hi Ztdep,

Thanks for your response.
One more question: Do you know where I can find LU decomposition for sparse matrix (article, reference)?

Best regards,
Hector.
HectorRedal is offline   Reply With Quote

Old   July 20, 2012, 07:55
Default
  #4
Senior Member
 
ztdep's Avatar
 
p ding
Join Date: Mar 2009
Posts: 427
Rep Power: 19
ztdep is on a distinguished road
Send a message via Yahoo to ztdep Send a message via Skype™ to ztdep
http://www.cise.ufl.edu/research/sparse/CSparse/

what is your matrix dimension?
if your matrix dimension is not very large, i think we can use the traditional computational method to compute it.
ztdep is offline   Reply With Quote

Old   July 20, 2012, 08:09
Default
  #5
Senior Member
 
Arjun
Join Date: Mar 2009
Location: Nurenberg, Germany
Posts: 1,285
Rep Power: 34
arjun will become famous soon enougharjun will become famous soon enough
Quote:
Originally Posted by HectorRedal View Post
Hi Ztdep,

Thanks for your response.
One more question: Do you know where I can find LU decomposition for sparse matrix (article, reference)?

Best regards,
Hector.

http://books.google.de/books/about/D...EC&redir_esc=y


One good book that also provides source code (i think).

Remember that LU factorization for sparse matrix may not be that sparse. Whether ILU is sufficient for your need or not is what shall think.
arjun is offline   Reply With Quote

Old   July 20, 2012, 09:53
Default
  #6
Senior Member
 
ztdep's Avatar
 
p ding
Join Date: Mar 2009
Posts: 427
Rep Power: 19
ztdep is on a distinguished road
Send a message via Yahoo to ztdep Send a message via Skype™ to ztdep
no ilu is incomplete lu , it is an approximation.

try to use lapack

http://www.netlib.org/lapack/double/dgetrf.f
* DGETRF computes an LU factorization of a general M-by-N matrix A
* using partial pivoting with row interchanges.
ztdep is offline   Reply With Quote

Old   July 20, 2012, 10:00
Default
  #7
Senior Member
 
Arjun
Join Date: Mar 2009
Location: Nurenberg, Germany
Posts: 1,285
Rep Power: 34
arjun will become famous soon enougharjun will become famous soon enough
Quote:
Originally Posted by ztdep View Post
no ilu is incomplete lu , it is an approximation.
http://people.sc.fsu.edu/~jburkardt/index.htmlffff

I am pretty sure what ILU is. I am also sure that calculating LU from sparse matrix is not efficient thing to do. Thats why I said think if ILU is sufficient for the needs.
arjun is offline   Reply With Quote

Old   July 21, 2012, 04:26
Default
  #8
Senior Member
 
Hector Redal
Join Date: Aug 2010
Location: Madrid, Spain
Posts: 243
Rep Power: 17
HectorRedal is on a distinguished road
Quote:
Originally Posted by ztdep View Post
http://www.cise.ufl.edu/research/sparse/CSparse/

what is your matrix dimension?
if your matrix dimension is not very large, i think we can use the traditional computational method to compute it.
Hi ztdep,

Thank you very much for the information you had provided to me. This is by far more than I needed. Thanks.

The matrix dimension for the LU decompostion varies from 2 to 10. This is the range I need.

I am developing a software for CFD using the finite element method, and for calculating the element matrices for the algorithm, I need the determinant of this matrices.

As mentioned before, I am thinking of using the LU decomposition for calculation of the determinant.
HectorRedal is offline   Reply With Quote

Old   July 21, 2012, 04:44
Default
  #9
Senior Member
 
Hector Redal
Join Date: Aug 2010
Location: Madrid, Spain
Posts: 243
Rep Power: 17
HectorRedal is on a distinguished road
Quote:
Originally Posted by arjun View Post
http://books.google.de/books/about/D...EC&redir_esc=y


One good book that also provides source code (i think).

Remember that LU factorization for sparse matrix may not be that sparse. Whether ILU is sufficient for your need or not is what shall think.
Hello Arjun,

Thanks for the information.
I agree with you that LU factorization may not be an sparse matrix.
The need for LU factorization is to compute the determinant of the sparse matrix.
That's the reason why I need it. Maybe, as you state, it is sufficient to compute the iLU for estimation of the determinant.
This is a good point to think about.

Thanks again.
HectorRedal is offline   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
Parallel algorithm to convert dense to sparse (CRS) matrix format Italo Main CFD Forum 0 December 19, 2011 04:01
Sparse solver for block-diagonal matrix alberto_cuoci Main CFD Forum 1 July 5, 2011 07:37
C++ solver for Large sparse matrix! sina_mech Main CFD Forum 7 November 20, 2009 14:52
OpenFOAM version 1.6 details lakeat OpenFOAM Running, Solving & CFD 42 August 26, 2009 22:47
Sparse matrix Takuya TSUJI Main CFD Forum 4 May 9, 2001 19:07


All times are GMT -4. The time now is 05:30.