Re: [petsc-users] Moving from KSPSetNullSpace to MatSetNullSpace

2016-10-25 Thread Matthew Knepley
On Tue, Oct 25, 2016 at 9:20 PM, Barry Smith wrote: > > Olivier, > > Ok, so I've run the code in the debugger, but I don't not think the > problem is with the null space. The code is correctly removing the null > space on all the levels of multigrid. > > I think the error comes from cha

Re: [petsc-users] Moving from KSPSetNullSpace to MatSetNullSpace

2016-10-25 Thread Barry Smith
Olivier, Ok, so I've run the code in the debugger, but I don't not think the problem is with the null space. The code is correctly removing the null space on all the levels of multigrid. I think the error comes from changes in the behavior of GAMG. GAMG is relatively rapidly moving

Re: [petsc-users] Moving from KSPSetNullSpace to MatSetNullSpace

2016-10-25 Thread Barry Smith
> On Oct 25, 2016, at 8:28 PM, Matthew Knepley wrote: > > On Tue, Oct 25, 2016 at 7:57 PM, Olivier Mesnard > wrote: > On 25 October 2016 at 19:59, Matthew Knepley wrote: > On Tue, Oct 25, 2016 at 6:22 PM, Barry Smith wrote: > > > On Oct 25, 2016, at 5:39 PM, Olivier Mesnard > > wrote: > >

Re: [petsc-users] Moving from KSPSetNullSpace to MatSetNullSpace

2016-10-25 Thread Matthew Knepley
On Tue, Oct 25, 2016 at 7:57 PM, Olivier Mesnard wrote: > On 25 October 2016 at 19:59, Matthew Knepley wrote: > >> On Tue, Oct 25, 2016 at 6:22 PM, Barry Smith wrote: >> >>> >>> > On Oct 25, 2016, at 5:39 PM, Olivier Mesnard < >>> olivier.mesna...@gmail.com> wrote: >>> > >>> > On 25 October 201

[petsc-users] How to scatter values

2016-10-25 Thread ztdepya...@163.com
Dear professor: I  partitioned my 2D cartesian  grid with  4rows*4cols CPUS.    12  13 14 15      8   9  10  11 4   5  6  7 0   1  2   3        Now i need to scatter the values  belonging to cpu5 to every cpu along

Re: [petsc-users] Moving from KSPSetNullSpace to MatSetNullSpace

2016-10-25 Thread Olivier Mesnard
On 25 October 2016 at 19:59, Matthew Knepley wrote: > On Tue, Oct 25, 2016 at 6:22 PM, Barry Smith wrote: > >> >> > On Oct 25, 2016, at 5:39 PM, Olivier Mesnard < >> olivier.mesna...@gmail.com> wrote: >> > >> > On 25 October 2016 at 17:51, Barry Smith wrote: >> > >> > Olivier, >> > >> > I

Re: [petsc-users] Moving from KSPSetNullSpace to MatSetNullSpace

2016-10-25 Thread Matthew Knepley
On Tue, Oct 25, 2016 at 6:22 PM, Barry Smith wrote: > > > On Oct 25, 2016, at 5:39 PM, Olivier Mesnard > wrote: > > > > On 25 October 2016 at 17:51, Barry Smith wrote: > > > > Olivier, > > > > In theory you do not need to change anything else. Are you using a > different matrix object for

Re: [petsc-users] Moving from KSPSetNullSpace to MatSetNullSpace

2016-10-25 Thread Barry Smith
> On Oct 25, 2016, at 5:39 PM, Olivier Mesnard > wrote: > > On 25 October 2016 at 17:51, Barry Smith wrote: > > Olivier, > > In theory you do not need to change anything else. Are you using a > different matrix object for the velocity_ksp object than the poisson_ksp > object? > > ​T

Re: [petsc-users] Moving from KSPSetNullSpace to MatSetNullSpace

2016-10-25 Thread Olivier Mesnard
On 25 October 2016 at 17:51, Barry Smith wrote: > > Olivier, > > In theory you do not need to change anything else. Are you using a > different matrix object for the velocity_ksp object than the poisson_ksp > object? > > ​The matrix is different for the velocity_ksp and the poisson_ksp​.

Re: [petsc-users] Moving from KSPSetNullSpace to MatSetNullSpace

2016-10-25 Thread Barry Smith
Olivier, In theory you do not need to change anything else. Are you using a different matrix object for the velocity_ksp object than the poisson_ksp object? The code change in PETSc is very little but we have a report from another CFD user who also had problems with the change so the

[petsc-users] Moving from KSPSetNullSpace to MatSetNullSpace

2016-10-25 Thread Olivier Mesnard
Hi all, We develop a CFD code using the PETSc library that solves the Navier-Stokes equations using the fractional-step method from Perot (1993). At each time-step, we solve two systems: one for the velocity field, the other, a Poisson system, for the pressure field. One of our test-cases is a 2D

Re: [petsc-users] Using PETSc solvers and preconditioners with mfem

2016-10-25 Thread Tzanio Kolev
>> Stefano Zampini >> replied to the issue on github and was stating that there is some intention >> to get MFEM working with PETSc but there is no specific timeframe. > > There’s currently an open pull request for PETSc solvers inside the private > MFEM repo. > However, I don’t know when the c

Re: [petsc-users] Using PETSc solvers and preconditioners with mfem

2016-10-25 Thread Matthew Knepley
On Tue, Oct 25, 2016 at 1:43 PM, Jed Brown wrote: > Stefano Zampini writes: > > MATHYPRE could be a shell wrapping Hypre calls for the moment. > > However, HypreParCSR and MATAIJ are mostly equivalent formats. As far as > I know, the main (only?) difference resides in the fact that the diagonal

Re: [petsc-users] Using PETSc solvers and preconditioners with mfem

2016-10-25 Thread Jed Brown
Stefano Zampini writes: > MATHYPRE could be a shell wrapping Hypre calls for the moment. > However, HypreParCSR and MATAIJ are mostly equivalent formats. As far as I > know, the main (only?) difference resides in the fact that the diagonal term > of the diagonal part is ordered first in the CSR.

Re: [petsc-users] Using PETSc solvers and preconditioners with mfem

2016-10-25 Thread Barry Smith
> On Oct 25, 2016, at 12:31 PM, Matthew Knepley wrote: > > On Tue, Oct 25, 2016 at 12:19 PM, Stefano Zampini > wrote: > I have a working conversion from HypreParCSR to PETSc MPIAIJ format. > I could add this code to PETSc, maybe in the contrib folder. Barry, what do > you think? > > No, no o

Re: [petsc-users] Using PETSc solvers and preconditioners with mfem

2016-10-25 Thread Stefano Zampini
On Oct 25, 2016, at 9:10 PM, Julian Andrej wrote: > We have an implementation which models a real physical application but > don't have the manpower to implement different preconditioner themes > (like with fieldsplit) or try out different time solving schemes > (which is way too easy with TS).

Re: [petsc-users] Using PETSc solvers and preconditioners with mfem

2016-10-25 Thread Julian Andrej
We have an implementation which models a real physical application but don't have the manpower to implement different preconditioner themes (like with fieldsplit) or try out different time solving schemes (which is way too easy with TS). Specifically we create a bunch of operators (Boundary and Fac

Re: [petsc-users] Using PETSc solvers and preconditioners with mfem

2016-10-25 Thread Stefano Zampini
On Oct 25, 2016, at 8:50 PM, Jed Brown wrote: > Matthew Knepley writes: > >> On Tue, Oct 25, 2016 at 12:19 PM, Stefano Zampini >> wrote: >> >>> I have a working conversion from HypreParCSR to PETSc MPIAIJ format. >>> I could add this code to PETSc, maybe in the contrib folder. Barry, what >>>

Re: [petsc-users] Using PETSc solvers and preconditioners with mfem

2016-10-25 Thread Matthew Knepley
On Tue, Oct 25, 2016 at 12:50 PM, Jed Brown wrote: > Matthew Knepley writes: > > > On Tue, Oct 25, 2016 at 12:19 PM, Stefano Zampini < > stefano.zamp...@gmail.com > >> wrote: > > > >> I have a working conversion from HypreParCSR to PETSc MPIAIJ format. > >> I could add this code to PETSc, maybe

Re: [petsc-users] Using PETSc solvers and preconditioners with mfem

2016-10-25 Thread Abdullah Ali Sivas
@Stefano Zampini: I am planning to do two things. One is to directly use Krylov solvers and preconditioners available to PETSc to try out some stuff and make some matrix manipulations like symmetric diagonal scaling or getting a submatrix. If that works I will implement few things (preconditio

Re: [petsc-users] Using PETSc solvers and preconditioners with mfem

2016-10-25 Thread Jed Brown
Matthew Knepley writes: > On Tue, Oct 25, 2016 at 12:19 PM, Stefano Zampini > wrote: > >> I have a working conversion from HypreParCSR to PETSc MPIAIJ format. >> I could add this code to PETSc, maybe in the contrib folder. Barry, what >> do you think? >> > > No, no one looks there. Add it to src/

Re: [petsc-users] Using PETSc solvers and preconditioners with mfem

2016-10-25 Thread Matthew Knepley
On Tue, Oct 25, 2016 at 12:19 PM, Stefano Zampini wrote: > I have a working conversion from HypreParCSR to PETSc MPIAIJ format. > I could add this code to PETSc, maybe in the contrib folder. Barry, what > do you think? > No, no one looks there. Add it to src/mat/utils and make an interface funct

Re: [petsc-users] Using PETSc solvers and preconditioners with mfem

2016-10-25 Thread Stefano Zampini
I have a working conversion from HypreParCSR to PETSc MPIAIJ format. I could add this code to PETSc, maybe in the contrib folder. Barry, what do you think? > We tried a similar approach to get MFEM objects to PETSc and the real > problem is that all other convenient functions like creating > gri

Re: [petsc-users] Using PETSc solvers and preconditioners with mfem

2016-10-25 Thread Julian Andrej
We tried a similar approach to get MFEM objects to PETSc and the real problem is that all other convenient functions like creating gridfunctions and projections, you have to convert them every time which is basically nothing more than a bad workaround. Stefano Zampini replied to the issue on github

Re: [petsc-users] Using PETSc solvers and preconditioners with mfem

2016-10-25 Thread Abdullah Ali Sivas
I will check that. I am preallocating but it may be that I am not allocating big enough. I still have to figure out nuance differences between these formats to solve the bugs. I appreciate your answer and hope Satish knows it. Thank you, Abdullah Ali Sivas On 2016-10-25 12:15 PM, Matthew Kne

Re: [petsc-users] SuperLU_dist issue in 3.7.4

2016-10-25 Thread Hong
Sherry, We set '-mat_superlu_dist_fact SamePattern' as default in petsc/superlu_dist on 12/6/15 (see attached email below). However, Anton must set 'SamePattern_SameRowPerm' to avoid crash in his code. Checking http://crd-legacy.lbl.gov/~xiaoye/SuperLU/superlu_dist_code_html/pzgssvx___a_bglobal_

Re: [petsc-users] Using PETSc solvers and preconditioners with mfem

2016-10-25 Thread Matthew Knepley
On Tue, Oct 25, 2016 at 10:54 AM, Abdullah Ali Sivas < abdullahasi...@gmail.com> wrote: > Hello, > > I want to use PETSc with mfem and I know that mfem people will figure out > a way to do it in few months. But for now as a temporary solution I just > thought of converting hypre PARCSR matrices (t

[petsc-users] Using PETSc solvers and preconditioners with mfem

2016-10-25 Thread Abdullah Ali Sivas
Hello, I want to use PETSc with mfem and I know that mfem people will figure out a way to do it in few months. But for now as a temporary solution I just thought of converting hypre PARCSR matrices (that is what mfem uses as linear solver package) into PETSc MPIAIJ matrices and I have a semi-

Re: [petsc-users] SuperLU_dist issue in 3.7.4

2016-10-25 Thread Hong
Anton, I guess, when you reuse matrix and its symbolic factor with updated numerical values, superlu_dist requires this option. I'm cc'ing Sherry to confirm it. I'll check petsc/superlu-dist interface to set this flag for this case. Hong On Tue, Oct 25, 2016 at 8:20 AM, Anton Popov wrote: > Ho

Re: [petsc-users] error with wrong tarball in path/to/package

2016-10-25 Thread Satish Balay
>>> Looking for ML at git.ml, hg.ml or a directory starting with petsc-pkg-ml Could not locate an existing copy of ML: ['ml-6.2'] <<< So configure was looking for something with 'petsc-pkg-ml' - and it did not find it. [there was 'ml-6

Re: [petsc-users] error with wrong tarball in path/to/package

2016-10-25 Thread Satish Balay
Always look in configure.log to see the exact error. No - configure does not do checksums - but it expcects the package to be in a certain format [and this can change between petsc versions]. So if you are using a url from petsc-3.5 - with 3.7 -- it might not work.. So for any version of petsc -

Re: [petsc-users] SuperLU_dist issue in 3.7.4

2016-10-25 Thread Anton Popov
Hong, I get all the problems gone and valgrind-clean output if I specify this: -mat_superlu_dist_fact SamePattern_SameRowPerm What does SamePattern_SameRowPerm actually mean? Row permutations are for large diagonal, column permutations are for sparsity, right? Will it skip subsequent matrix pe

Re: [petsc-users] Element to local dof map using dmplex

2016-10-25 Thread Matthew Knepley
On Tue, Oct 25, 2016 at 6:39 AM, Morten Nobel-Jørgensen wrote: > Dear Matt > > Did you (or anyone else) find time to look at our issue? > > We are really looking forward to your answer :) > Yes, I had a little difficulty understanding what was going on, but now I think I see. I am attaching my m

Re: [petsc-users] SuperLU_dist issue in 3.7.4 failure of repeated calls to MatLoad() or MatMPIAIJSetPreallocation() with the same matrix

2016-10-25 Thread Anton Popov
On 10/25/2016 01:58 PM, Anton Popov wrote: On 10/24/2016 10:32 PM, Barry Smith wrote: Valgrind doesn't report any problems? Valgrind hangs and never returns (waited hours for a 5 sec run) after entering factorization for the second time. Before it happens it prints this (attached)

Re: [petsc-users] SuperLU_dist issue in 3.7.4 failure of repeated calls to MatLoad() or MatMPIAIJSetPreallocation() with the same matrix

2016-10-25 Thread Anton Popov
On 10/24/2016 10:32 PM, Barry Smith wrote: Valgrind doesn't report any problems? Valgrind hangs and never returns (waited hours for a 5 sec run) after entering factorization for the second time. On Oct 24, 2016, at 12:09 PM, Anton Popov wrote: On 10/24/2016 05:47 PM, Hong wrote:

Re: [petsc-users] Element to local dof map using dmplex

2016-10-25 Thread Morten Nobel-Jørgensen
Dear Matt Did you (or anyone else) find time to look at our issue? We are really looking forward to your answer :) Kind regards, Morten From: Matthew Knepley [knep...@gmail.com] Sent: Wednesday, October 12, 2016 3:41 PM To: Morten Nobel-Jørgensen Cc: petsc-users@

[petsc-users] error with wrong tarball in path/to/package

2016-10-25 Thread Klaij, Christiaan
Here is a small complaint about the error message "unable to download" that is given when using --download-PACKAGENAME=/PATH/TO/package.tar.gz with the wrong tarball. For example, for my previous install, I was using petsc-3.5.3 with: --download-ml=/path/to/ml-6.2-win.tar.gz Using the same file

Re: [petsc-users] BVNormColumn

2016-10-25 Thread Jose E. Roman
> El 19 oct 2016, a las 9:54, Jose E. Roman escribió: > >> >> El 19 oct 2016, a las 0:26, Bikash Kanungo escribió: >> >> Hi Jose, >> >> Thanks for the pointers. Here's what I observed on probing it further: >> >> • The ||B - B^H|| norm was 1e-18. So I explicitly made it Hermitian by >