Re: [petsc-users] [TimeStepping] Eventhandler

2019-02-04 Thread Huck, Moritz via petsc-users
as an added issue. The steps to complete the time interval after event detection, seem to be done with the intial step, this leads to man steps with a very small step for me. (e.g. my initial step is 1e-6 but the event at 1000s is detected in [980..1070] is nedd to to take 70e6 steps with dt=1e-6

Re: [petsc-users] Queries related to snes options

2019-02-04 Thread Mark Adams via petsc-users
On Mon, Feb 4, 2019 at 6:05 AM Aman Saxena via petsc-users < petsc-users@mcs.anl.gov> wrote: > I am trying to use PETSc's TS to implement implicit time-stepping, for > 1d-Euler Equation discretized using 5th order WENO schemes. I have > following queries related to using some of the snes options::

[petsc-users] Doubt on how to copy a Mat into another (Fortran)

2019-02-04 Thread Marco Tiberga via petsc-users
Dear PETSc developers, Since I am learning how to use MatCreateNest, I was looking at example ex73f90t.F90 (I am using Fortran). At line 297, the array of matrices to be passed to MatCreateNest is initial

Re: [petsc-users] Preconditioning systems of equations with complex numbers

2019-02-04 Thread Justin Chang via petsc-users
Thanks everyone for your suggestions/feedback. So a few things: 1) When I examined larger distribution networks (~150k buses) my eigenvalue estimates from the chebyshev method get enormous indeed. See below: [0] PCSetUp_GAMG(): level 0) N=320745, n data rows=1, n data cols=1, nnz/row (ave)=6, np=

Re: [petsc-users] Preconditioning systems of equations with complex numbers

2019-02-04 Thread Jed Brown via petsc-users
Matthew Knepley via petsc-users writes: >> 2) I tried all the suggestions mentioned before: setting >> -pc_gamg_agg_nsmooths 0 -pc_gamg_square_graph 10 did not improve my >> convergence. Neither did explicitly setting -mg_coarse_pc_type lu or more >> iterations of richardson/sor. >> > > 1) Can w

Re: [petsc-users] PETSC matrix assembling super slow

2019-02-04 Thread Yaxiong Chen via petsc-users
Hi Mark, Will the parameter MatMPIAIJSetPreallocation in influence the following part do i=mystart,nelem,nproc call ptSystem%getElementalMAT(i, Ae, auxRHSe, idx) ne=size(idx) idx=idx-1 !-1 since PETSC index starts from zero if

Re: [petsc-users] PETSC matrix assembling super slow

2019-02-04 Thread Smith, Barry F. via petsc-users
> On Feb 4, 2019, at 3:17 PM, Yaxiong Chen via petsc-users > wrote: > > Hi Mark, > Will the parameter MatMPIAIJSetPreallocation in influence the following > part > do i=mystart,nelem,nproc > call ptSystem%getElementalMAT(i, Ae, auxRHSe, idx) > ne=size(idx) >

Re: [petsc-users] [TimeStepping] Eventhandler

2019-02-04 Thread Smith, Barry F. via petsc-users
> > Is there any reason you'd like to use the last time step? We used the initial > time-step (which is assumed to be small) so as (a) to minimize any numerical > issues that may be caused by a large last time-step, and (b) to not miss any > ensuing events that may be triggered by the discontin

Re: [petsc-users] PETSC matrix assembling super slow

2019-02-04 Thread Smith, Barry F. via petsc-users
> On Feb 4, 2019, at 4:41 PM, Yaxiong Chen wrote: > > Hi Barry, > > !=== > mystart =rank +1! rank starts from 0 > do i=mystart,nelem,nproc! nelem: total number of > elements

Re: [petsc-users] [TimeStepping] Eventhandler

2019-02-04 Thread Smith, Barry F. via petsc-users
Ahh, thanks, for some reason I didn't find that. Based on Moritz's code example perhaps we need to add one or more TSEvent methods. The simplest thing would be to have a routine to allow reseting the "base" timestep that is used 1) within the TSEvent search and 2) after an event is found.

Re: [petsc-users] Preconditioning systems of equations with complex numbers

2019-02-04 Thread Smith, Barry F. via petsc-users
> On Feb 4, 2019, at 1:56 PM, Justin Chang via petsc-users > wrote: > > Thanks everyone for your suggestions/feedback. So a few things: > > 1) When I examined larger distribution networks (~150k buses) my eigenvalue > estimates from the chebyshev method get enormous indeed. See below: > >