[petsc-users] Best way to setup TS to use TSBASICSYMPLECTIC

Matthew Knepley knepley at gmail.com
Thu Apr 2 06:12:30 CDT 2020


On Wed, Apr 1, 2020 at 9:31 PM Dharmendar Reddy <dharmareddy84 at gmail.com>
wrote:

> Hello,
> What is the suggested way to used TSBASICSYMPLECTIC.
>
> Lines below from ./src/dm/impls/swarm/examples/tests/ex5.c:[430-431]
>
>   /* DM needs to be set before splits so it propogates to sub TSs */
>   ierr = TSSetDM(ts, sw);CHKERRQ(ierr);
>   ierr = TSSetType(ts,TSBASICSYMPLECTIC);CHKERRQ(ierr);
>
> seem to suggest that DM is necessary to use TSBASICSYMPLECTIC solver.
>

It is not.


> I am trying to test the solve for a system of coupled particles with all
> to all position dependent interaction:
> For a set of N particles with i=1 to N
> ddt(x_i) = v_i  ;
>
> ddt(v_i) = (J x X)_i // i th component of matrix J times position vector X;
>
> where J is the coupling matrix and X is the position vector of all
> particles.
>
> I tried testing with code similar to
> ./src/ts/examples/tutorials/hamiltonian/ex1.c
>
> where J will be a diagonal matrix with -omega*omgea as diagonal elements.
>

What is the problem?

  Thanks,

     Matt


> Thanks
> REddy
>
>
>

-- 
What most experimenters take for granted before they begin their
experiments is infinitely more interesting than any results to which their
experiments lead.
-- Norbert Wiener

https://www.cse.buffalo.edu/~knepley/ <http://www.cse.buffalo.edu/~knepley/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20200402/4abdc05d/attachment.html>


More information about the petsc-users mailing list