This forum has been archived. All content is frozen. Please use KDE Discuss instead.

SparseVector coeffRef without insert

Tags: None
(comma "," separated)
pauldb
Registered Member
Posts
1
Karma
0
I have a previously populated SparseVector<double> and now I'd like to retrieve the values at various indexes or 0 if those values haven't been set. coeffRef seems to do the job, but it inserts new entries in the vector for unseen indexes. Is there a way to do this without changing the vector?
User avatar
ggael
Moderator
Posts
3447
Karma
19
OS
coeff() will do the job.


Bookmarks



Who is online

Registered users: Bing [Bot], Google [Bot], Yahoo [Bot]