Re: [eigen] Reusing a sparse matrix for SparseLU |

[ Thread Index | Date Index | More lists.tuxfamily.org/eigen Archives ]

*To*: eigen@xxxxxxxxxxxxxxxxxxx*Subject*: Re: [eigen] Reusing a sparse matrix for SparseLU*From*: Matthieu Brucher <matthieu.brucher@xxxxxxxxx>*Date*: Mon, 3 Dec 2018 15:51:05 +0000*Dkim-signature*: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=yd6uXY1TlYbA3GgUZSfTwpQekc6dBVjQlDRA0J9iYjU=; b=IiSdnT43xol4x8Er49bQcO57Xl/Ml2Xk9iHGcbCPfPmgFJs8qJUo29TxkO1uKupcxD SYTd07sINFZsNp1GX4FJEPQIGqB5iG4AzynGBPmTjoY/vXXR4QnC140umjnTEOmOkRcY JouQC0ew5y5Siws1FrSa6EHTFJYxF+6iZ5Ot0HUIrA7wOIRvppgOyP6KLg6tBAaY/nPs V/UgshbFRexxuxXz5TiypA+lF8/W+sCKrSBoxLRr8XIx60XK0+ZlYfEmm0mXdU5Yvywk TuiJVTGs/lGRKYYo60MC/5G+oUKTQMtv01fkl4kuRa5nZu0TA3T0NuxSpL2HJndBEpoL cxEA==

Hi Gael,

The typical size is between 10 and 50, between 3 and 5 entries per row, but it has to run fast, without memory allocations.

I tried SpaseLU, but indeed, still twice as slow as dense Householder QR for the lower end of my range. The "nice" thing is that I can generate the structure offline (it's for a JIT PDE solver) and do lots of analysis before (column permutations and all that stuff).

Cheers,

Matthieu

Le lun. 3 déc. 2018 à 15:07, Gael Guennebaud <gael.guennebaud@xxxxxxxxx> a écrit :

hm.... if you're thinking about using coeffs() << v0, v1, v2... then your matrix is likely very small. What is its typical size and number of non-zeros? If too small and not sparse enough better use a dense matrix/solver..gaelOn Mon, Dec 3, 2018 at 2:28 PM Matthieu Brucher <matthieu.brucher@xxxxxxxxx> wrote:Le lun.. 3 déc. 2018 à 11:43, Alberto Luaces <alberto.luaces@xxxxxxxxx> a écrit :Matthieu Brucher writes:

> Hi Alberto,

>

> Thanks for the answer. Unfortunately, this still makes me create

> another array,

How so?I need to create an array for the coifs, don't I? Seems like I could use valuePtr as well.But the speed is very bad and profiles indicate that there may be mallocs inside the factorisation or the solve :/

> I'd rather populate the elements directly.

You can do precisely that, by using the coeffs() vector.Oh, you mean I could do coeffs() << v0, v1, v2...?--Quantitative analyst, Ph.D.

Blog: http://blog.audio-tk.com/

LinkedIn: http://www.linkedin.com/in/matthieubrucher

Quantitative analyst, Ph.D.

Blog: http://blog.audio-tk.com/

LinkedIn: http://www.linkedin.com/in/matthieubrucher

Blog: http://blog.audio-tk.com/

LinkedIn: http://www.linkedin.com/in/matthieubrucher

**References**:**[eigen] Reusing a sparse matrix for SparseLU***From:*Matthieu Brucher

**Re: [eigen] Reusing a sparse matrix for SparseLU***From:*Alberto Luaces

**Re: [eigen] Reusing a sparse matrix for SparseLU***From:*Matthieu Brucher

**Re: [eigen] Reusing a sparse matrix for SparseLU***From:*Alberto Luaces

**Re: [eigen] Reusing a sparse matrix for SparseLU***From:*Matthieu Brucher

**Re: [eigen] Reusing a sparse matrix for SparseLU***From:*Gael Guennebaud

**Messages sorted by:**[ date | thread ]- Prev by Date:
**Re: [eigen] Reusing a sparse matrix for SparseLU** - Next by Date:
**[eigen] 3.3.6 released!** - Previous by thread:
**Re: [eigen] Reusing a sparse matrix for SparseLU** - Next by thread:
**Re: [eigen] Reusing a sparse matrix for SparseLU**

Mail converted by MHonArc 2.6.19+ | http://listengine.tuxfamily.org/ |