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*: Alberto Luaces <alberto.luaces@xxxxxxxxx>*Date*: Mon, 03 Dec 2018 11:26:19 +0100

Matthieu Brucher writes: > Now,, I'd like to reuse the matrix instead of creating a new one, as I'm doing real-time computations and don't want any allocation there. > > Can I use the comma operator? Or is there another operator that I can use to update the matrix existing entries? I tried to find information online but couldn't find the best practice for this. > Hi, as per https://stackoverflow.com/questions/40593324/how-to-avoid-memory-allocations-in-sparse-expressions-with-eigen you can use m.coeffs() to update the non-zero elements of the matrix as a large array. -- Alberto

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

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

**Messages sorted by:**[ date | thread ]- Prev by Date:
**[eigen] Logical expression with BLAS version error?** - Next by Date:
**Re: [eigen] Reusing a sparse matrix for SparseLU** - Previous by thread:
**[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/ |