This is a read only copy of the old FEniCS QA forum. Please visit the new QA forum to ask questions

Matrix add/set

+1 vote

Matrix has functions add/set to change the values inside the Matrix. But I have to add/set a block of matrix. Can I just add/set a sparse matrix (stored in CSR data structure)?

I know I can add the element one by one in sparse matrix, but I think the time cost will be huge, because there are a lot of data movement in each add operation. Is there a simpler way to do it?

asked Mar 20, 2014 by vincehouhou FEniCS Novice (540 points)
...