Re: [petsc-users] MatCompositeMerge + MatCreateRedundantMatrix

2019-03-19 Thread Marius Buerkle via petsc-users
If it is not too complicated it would be nice if MPICreateSubMatricesMPI  would be avaible for other matrices than MPIAIJ.       On Mon, Mar 18, 2019 at 10:30 PM Marius Buerkle wrote: I have another question regarding MatCreateRedundantMatrix and MPICreateSubMatricesMPI.

Re: [petsc-users] MatCompositeMerge + MatCreateRedundantMatrix

2019-03-18 Thread Marius Buerkle via petsc-users
I have another question regarding MatCreateRedundantMatrix and MPICreateSubMatricesMPI. The former works for MPIAIJ and  MPIDENSE and the later only for MPIAIJ. Would it be possible to use MatCreateRedundantMatrix with a factored matrix and MPICreateSubMatricesMPI with dense and/or elemental

Re: [petsc-users] MatCompositeMerge + MatCreateRedundantMatrix

2019-03-13 Thread Marius Buerkle via petsc-users
Indeed, was very easy to add. Are you going to include the Fortran interface for MPICreateSubMatricesMPI  in future releases of PETSC ? Regarding my initial problem, thanks a lot. It works very well with MPICreateSubMatricesMPI  and the solution can be implemented in a few lines. Thanks and

Re: [petsc-users] MatCompositeMerge + MatCreateRedundantMatrix

2019-03-12 Thread Marius Buerkle via petsc-users
I tried to follow your suggestions but it seems there is no MPICreateSubMatricesMPI for Fortran. Is this correct?   On Wed, Feb 20, 2019 at 6:57 PM Marius Buerkle wrote: ok, I think I understand now. I will give it a try and if there is some trouble comeback to you.

Re: [petsc-users] MatCompositeMerge + MatCreateRedundantMatrix

2019-02-20 Thread Marius Buerkle via petsc-users
ok, I think I understand now. I will give it a try and if there is some trouble comeback to you. thanks.   marius   On Tue, Feb 19, 2019 at 8:42 PM Marius Buerkle wrote: ok, so it seems there is no straight forward way to transfer data between PETSc matrices on

Re: [petsc-users] MatCompositeMerge + MatCreateRedundantMatrix

2019-02-19 Thread Marius Buerkle via petsc-users
ok, so it seems there is no straight forward way to transfer data between PETSc matrices on different subcomms. Probably doing it by "hand" extracting the matricies on the subcomms create a MPI_INTERCOMM transfering the data to PETSC_COMM_WORLD and assembling them in a new PETSc matrix would be

Re: [petsc-users] MatCompositeMerge + MatCreateRedundantMatrix

2019-02-19 Thread Matthew Knepley via petsc-users
You basically need the inverse of MatCreateSubmatrices(). I do not think we have that right now, but it could probably be done without too much trouble by looking at that code. Thanks, Matt On Tue, Feb 19, 2019 at 6:15 AM Marius Buerkle via petsc-users < petsc-users@mcs.anl.gov> wrote:

[petsc-users] MatCompositeMerge + MatCreateRedundantMatrix

2019-02-19 Thread Marius Buerkle via petsc-users
Hi !   Is there some way to combine MatCompositeMerge with MatCreateRedundantMatrix? I basically want to create copies of a matrix from PETSC_COMM_WORLD to subcommunicators, do some work on each subcommunicator and than gather the results back to PETSC_COMM_WORLD, namely  I want to sum the  the