Re: [petsc-users] Problems imposing boundary conditions

2017-03-17 Thread Sander Arens
Thanks, Sander On 14 March 2017 at 16:17, Sander Arens wrote: > I updated my pull request with a fix. If Matt approves and merges to > master, the problem should be solved. > > Thanks, > Sander > > On 9 March 2017 at 15:00, Matthew Knepley wrote: > >> On T

Re: [petsc-users] Problems imposing boundary conditions

2017-03-14 Thread Sander Arens
ec to a local Vec >> to being assembly. >> >> Thanks, >> >> Matt >> >> >>> Thanks, >>> Max >>> >>> >>> >>> Thanks, >>> >>> Matt >>> >>> >>>> Thanks, >

Re: [petsc-users] Problems imposing boundary conditions

2017-03-04 Thread Sander Arens
t this error also when running in serial. > > Thanks, > Max > > On 3 Mar 2017, at 22:14, Matthew Knepley wrote: > > On Fri, Mar 3, 2017 at 12:56 PM, Sander Arens > wrote: > >> Max, >> >> I'm assuming you use DMPlex for your mesh? If so, did you only

Re: [petsc-users] Problems imposing boundary conditions

2017-03-03 Thread Sander Arens
Max, I'm assuming you use DMPlex for your mesh? If so, did you only specify the faces in the DMLabel (and not vertices or edges). Do you get this error only in parallel? If so, I can confirm this bug. I submitted a pull request for this yesterday. On 3 March 2017 at 18:43, Lukas van de Wiel wro

[petsc-users] Visualization of uninterpolated DMPlex with hdf5 is broken

2017-01-11 Thread Sander Arens
Visualization of uninterpolated DMPlex with hdf5 currently does not work. I think the culprit is this line. Is this to avoid duplicating

Re: [petsc-users] how to output components of a section

2016-11-07 Thread Sander Arens
gt; ierr = DMRestoreGlobalVector(dm, &X);CHKERRQ(ierr); >> > > > I have add "VecSetDm", but it has not output file. > > Thanks > leejearl > > On 2016年11月07日 15:35, Sander Arens wrote: > > Does it work if you put > ierr = VecSetDM(subX, su

Re: [petsc-users] how to output components of a section

2016-11-06 Thread Sander Arens
gt;>> in th local vector. >>> >>This should work on the global vector. Please send the full output of >> the error messages when used with a global vector. >> >> Barry >> >> Is there any methods to reach this purposes in the global vector? &

Re: [petsc-users] how to output components of a section

2016-11-05 Thread Sander Arens
You can first obtain an IS with http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/DM/DMCreateSubDM.html and with that you can obtain a subvector with http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Vec/VecGetSubVector.html which you can then view the usual way. Thanks, Sander

Re: [petsc-users] DG within DMPlex

2016-10-04 Thread Sander Arens
I think it would also be interesting to have something similar to TS ex25, but now with DMPlex and DG. On 4 October 2016 at 04:57, Justin Chang wrote: > Advection-diffusion equations. Perhaps SNES ex12 could be modified to > include an advection term? > > On Mon, Oct 3, 2016 at 9:52 PM, Barry Sm

Re: [petsc-users] Problems with Gmsh

2016-08-15 Thread Sander Arens
Are you using the master branch? A while ago I also had this problem which was caused by different vertex numberings being used by DMPlex and gmsh. But this is fixed now if you use master. Thanks, Sander On 14 August 2016 at 20:49, Santos Teixeira Frederico < fsant...@student.ethz.ch> wrote: > H

Re: [petsc-users] Problem with interpolating projected field of quadratic order

2016-06-22 Thread Sander Arens
hanks, Sander On 19 June 2016 at 23:03, Sander Arens wrote: > And the files of course. > > On 19 June 2016 at 23:02, Sander Arens wrote: > >> Thanks, Matt. That indeed made the problem for the test dissapear. >> >> However, there's still a problem when I try to

Re: [petsc-users] Problem with interpolating projected field of quadratic order

2016-06-19 Thread Sander Arens
Matthew Knepley wrote: > On Sat, Jun 18, 2016 at 12:49 PM, Sander Arens > wrote: > >> 1) Does the test run for you? >> >> >> I ran the tests and they all pass. >> >> 2) If so, then could it be that you assume something about the order of >>

Re: [petsc-users] Problem with interpolating projected field of quadratic order

2016-06-18 Thread Sander Arens
ion on the vertex numbering in DMPlexCreateFromCellList or DMPlexCreateFromFile that I'm not aware of? I hope I made the problem clearer now? Thanks, Sander On 18 June 2016 at 16:33, Matthew Knepley wrote: > On Sat, Jun 18, 2016 at 9:26 AM, Matthew Knepley > wrote: > >> On Sat, Jun 18, 20

[petsc-users] Problem with interpolating projected field of quadratic order

2016-06-18 Thread Sander Arens
Hello all, Recently I've been trying to run a fem problem using DMPlex, PetscFE, etc. using a mesh created with gmsh. I used DMPlexReverseCell to get rid of the negative jacobian determinants. However, I noticed another problem: when I projected the coordinates on a quadratic fem-field and interpo

Re: [petsc-users] Discretized fields at quadrature points

2016-04-08 Thread Sander Arens
Or perhaps there should be a flag for PETSCDUALSPACELAGRANGE to evaluate at the quadrature points? On 8 April 2016 at 17:35, Sander Arens wrote: > What does it stand for? Discrete Gauss? Maybe PETSCSPACEQUADRATURE is a > better name? > > The reason I want to use this is because

Re: [petsc-users] Discretized fields at quadrature points

2016-04-08 Thread Sander Arens
Apr 6, 2016 at 2:06 PM, Sander Arens > wrote: > >> Hi, >> >> I'd like to be able to represent some discretized fields at the >> quadrature points of a finite element, so I can easily use them with the >> plex residual/function evaluations. Is it possible to do

[petsc-users] Discretized fields at quadrature points

2016-04-06 Thread Sander Arens
Hi, I'd like to be able to represent some discretized fields at the quadrature points of a finite element, so I can easily use them with the plex residual/function evaluations. Is it possible to do this with PetscFECreateDefault and some command line options? I think what I need is PETSCSPACEDG fo

Re: [petsc-users] PetscDSSetJacobianPreconditioner causing DIVERGED_LINE_SEARCH for multi-field problem

2016-04-03 Thread Sander Arens
Great! It's added. Thanks, Sander On 3 April 2016 at 16:53, Matthew Knepley wrote: > Go ahead and add it. I will review everything. > > Thanks, > > Matt > > On Sun, Apr 3, 2016 at 9:26 AM, Sander Arens > wrote: > >> No problem. I think I solved

Re: [petsc-users] PetscDSSetJacobianPreconditioner causing DIVERGED_LINE_SEARCH for multi-field problem

2016-04-03 Thread Sander Arens
No problem. I think I solved the problem with the block size, so I wanted to know if I should also add this to my pull request or if I should make a separate one? Thanks, Sander On 3 April 2016 at 15:17, Matthew Knepley wrote: > On Sun, Apr 3, 2016 at 6:55 AM, Sander Arens > wrote: &g

Re: [petsc-users] PetscDSSetJacobianPreconditioner causing DIVERGED_LINE_SEARCH for multi-field problem

2016-04-03 Thread Sander Arens
Any thoughts on this, Matt? Thanks, Sander On 21 March 2016 at 09:49, Sander Arens wrote: > Matt, > > I think the problem is in DMCreateSubDM_Section_Private. The block size > can be counted there (very similar as in DMCreateMatrix_Plex) and then > passed down to the IS. I ca

Re: [petsc-users] PetscDSSetJacobianPreconditioner causing DIVERGED_LINE_SEARCH for multi-field problem

2016-03-21 Thread Sander Arens
bc's)? On 3 March 2016 at 18:02, Sander Arens wrote: > Ok, thanks for clearing that up! > > On 3 March 2016 at 18:00, Matthew Knepley wrote: > >> On Thu, Mar 3, 2016 at 10:48 AM, Sander Arens >> wrote: >> >>> So is the block size here refering to

Re: [petsc-users] PetscDSSetJacobianPreconditioner causing DIVERGED_LINE_SEARCH for multi-field problem

2016-03-03 Thread Sander Arens
Ok, thanks for clearing that up! On 3 March 2016 at 18:00, Matthew Knepley wrote: > On Thu, Mar 3, 2016 at 10:48 AM, Sander Arens > wrote: > >> So is the block size here refering to the dimension of the near-nullspace >> or has it something to do with the coarsening? >&

Re: [petsc-users] PetscDSSetJacobianPreconditioner causing DIVERGED_LINE_SEARCH for multi-field problem

2016-03-03 Thread Sander Arens
nes: found 3 nodes, limit used is 5 > > Thanks, > > Matt > > On Thu, Mar 3, 2016 at 10:28 AM, Sander Arens > wrote: > >> Sure, here it is. >> >> Thanks, >> Sander >> >> On 3 March 2016 at 15:33, Matthew Knepley wrote: >> >&

Re: [petsc-users] PetscDSSetJacobianPreconditioner causing DIVERGED_LINE_SEARCH for multi-field problem

2016-03-03 Thread Sander Arens
Sure, here it is. Thanks, Sander On 3 March 2016 at 15:33, Matthew Knepley wrote: > On Thu, Mar 3, 2016 at 8:05 AM, Sander Arens > wrote: > >> Yes, the matrix is created by one of the assembly functions in Plex, so >> that answers my question. I was confused by this b

Re: [petsc-users] PetscDSSetJacobianPreconditioner causing DIVERGED_LINE_SEARCH for multi-field problem

2016-03-03 Thread Sander Arens
3, 2016 at 7:49 AM, Sander Arens > wrote: > >> And how can I do this? Because when I look at all the options with -help >> I can strangely enough only find -fieldsplit_pressure_mat_block_size and >> not -fieldsplit_displacement_mat_block_size. >> > > Maybe I am m

Re: [petsc-users] PetscDSSetJacobianPreconditioner causing DIVERGED_LINE_SEARCH for multi-field problem

2016-03-03 Thread Sander Arens
AM, Sander Arens > wrote: > >> Ok, I forgot to call SNESSetJacobian(snes, J, P, NULL, NULL) with J != P, >> which caused to write the mass matrix into the (otherwise zero) (1,1) block >> of the Jacobian and which was the reason for the linesearch to fail. >> However, after f

Re: [petsc-users] PetscDSSetJacobianPreconditioner causing DIVERGED_LINE_SEARCH for multi-field problem

2016-03-03 Thread Sander Arens
and attaching it to the displacement field, does the matrix block size of the (0,0) block still have to be set for good performance with gamg? If so, how can I do this? Thanks, Sander On 2 March 2016 at 12:25, Matthew Knepley wrote: > On Wed, Mar 2, 2016 at 5:13 AM, Sander Arens > wrote: &

[petsc-users] PetscDSSetJacobianPreconditioner causing DIVERGED_LINE_SEARCH for multi-field problem

2016-03-02 Thread Sander Arens
Hi, I'm trying to set a mass matrix preconditioner for the Schur complement of an incompressible finite elasticity problem. I tried using the command PetscDSSetJacobianPreconditioner(prob, 1, 1, g0_pre_mass_pp, NULL, NULL, NULL) (field 1 is the Lagrange multiplier field). However, this causes a DI

Re: [petsc-users] DMPlexTSComputeIJacobianFEM

2016-02-17 Thread Sander Arens
Ok, great! Thanks Matt. On 17 February 2016 at 10:18, Matthew Knepley wrote: > I just added this, but it is only in 'next'. It will go into 'master' next > week I think. > > Thanks, > > Matt > > On Wed, Feb 17, 2016 at 3:16 AM, Sander A

[petsc-users] DMPlexTSComputeIJacobianFEM

2016-02-17 Thread Sander Arens
Hi all, Is there a DMPlexSNESComputeJacobianFEM equivalent for the TS, i.e. DMPlexTSComputeIJacobianFEM? Or is there a better way to assemble the Jacobian for the TS in the case of FEM?