← Back to team overview

dolfin team mailing list archive

Re: Matrix concatenation

 

On Tue, Sep 30, 2008 at 10:53 AM, Jed Brown <jed@xxxxxxxx> wrote:

> On Tue 2008-09-30 10:48, Evan Lezar wrote:
> > I was wondering what the best way is to concatenate PETSc matrices?  I am
> > currently using the set() method, but this takes quite a bit of time.
>
> What are you trying to do?  You should probably preallocate the full
> matrix from the beginning.
>

I am assembling a number of submatrices.  And then trying to concatenate
them to form one large eigensystem.  I do pre-allocate the matrix that I
want to place the entries in.

It may be that I would be able to use mixed elements to do the same thing.
I will see if I can get a code snippet together.

Evan


>
> Jed
>
> _______________________________________________
> DOLFIN-dev mailing list
> DOLFIN-dev@xxxxxxxxxx
> http://www.fenics.org/mailman/listinfo/dolfin-dev
>
>

Follow ups

References