# forum.alglib.net

ALGLIB forum
 It is currently Sun Jan 19, 2020 4:05 pm

 All times are UTC

### Forum rules

1. This forum can be used for discussion of both ALGLIB-related and general numerical analysis questions
2. This forum is English-only - postings in other languages will be removed.

 Page 1 of 1 [ 7 posts ]
 Print view Previous topic | Next topic
Author Message
 Post subject: Solver for symmetric, hermitian, real, sparse Linear SystemPosted: Fri Nov 08, 2019 4:21 pm

Joined: Fri Nov 08, 2019 4:09 pm
Posts: 4
I have a 2D-FEM-simulation and want to solve the linear equation system Ax = b for it.
Hence, my matrix is
- symmetric
- hermitian
- real
- sparse as on https://en.wikipedia.org/wiki/Sparse_matrix

Which solver is the best for my matrix?
And could you maybe give me a codesnippet of how to code it in C# beginning with:
Code:
alglib.sparsematrix s;

sparsesolvesks(...) works, but is not pretty fast ...

Top

 Post subject: Re: Solver for symmetric, hermitian, real, sparse Linear SysPosted: Mon Nov 11, 2019 8:20 am

Joined: Fri May 07, 2010 7:06 am
Posts: 854
1. How many variables do you have?
2. How many non-zero elements per entire matrix do you have?

Top

 Post subject: Re: Solver for symmetric, hermitian, real, sparse Linear SysPosted: Mon Nov 11, 2019 8:56 am

Joined: Fri Nov 08, 2019 4:09 pm
Posts: 4
1. around 5000x5000 matrix
2. around 10 non-zero-elements per row

Top

 Post subject: Re: Solver for symmetric, hermitian, real, sparse Linear SysPosted: Tue Nov 12, 2019 9:02 am

Joined: Fri May 07, 2010 7:06 am
Posts: 854
Did you try sparselu() function?

Ideally, you should use Cholesky for positive definite matrices - but presently we do not have sparse Cholesky in ALGLIB, it is planned to be included in version 3.17.0 (we have a lot of stuff in upcoming 3.16.0 which will benefit from sparse Cholesky, so it is of high priority for us).

Top

 Post subject: Re: Solver for symmetric, hermitian, real, sparse Linear SysPosted: Thu Nov 14, 2019 7:58 am

Joined: Fri Nov 08, 2019 4:09 pm
Posts: 4
Yes, Cholesky would be very nice and I am very interested in implementing this to ALGLIB :)

Top

 Post subject: Re: Solver for symmetric, hermitian, real, sparse Linear SysPosted: Fri Nov 15, 2019 12:43 pm

Joined: Fri Nov 08, 2019 4:09 pm
Posts: 4
How do i get a row permutation matrix and a column permutation matrix?

Top

 Post subject: Re: Solver for symmetric, hermitian, real, sparse Linear SysPosted: Fri Nov 15, 2019 2:29 pm

Joined: Fri May 07, 2010 7:06 am
Posts: 854
alglib::sparselu returns them in parameters p and q, as product of individual permutations (see subroutine comments for exact format)

Top

 Display posts from previous: All posts1 day7 days2 weeks1 month3 months6 months1 year Sort by AuthorPost timeSubject AscendingDescending
 Page 1 of 1 [ 7 posts ]

 All times are UTC

#### Who is online

Users browsing this forum: Bing [Bot] and 1 guest

 You cannot post new topics in this forumYou cannot reply to topics in this forumYou cannot edit your posts in this forumYou cannot delete your posts in this forumYou cannot post attachments in this forum

Search for: