[petsc-users] Best way to setup TS to use TSBASICSYMPLECTIC
Dharmendar Reddy
dharmareddy84 at gmail.com
Wed Apr 1 20:30:39 CDT 2020
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.
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.
Thanks
REddy
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20200401/5f95c9f3/attachment.html>
More information about the petsc-users
mailing list