[petsc-users] [Fortran] VTK viewer error

Jed Brown jedbrown at mcs.anl.gov
Thu Apr 18 20:44:19 CDT 2013


Dharmendar Reddy <dharmareddy84 at gmail.com> writes:

> Sorry Again. I always use to use reply and the mail went to petsc-users.
> Only since last few days it is not going to petsc-users. I will make sure i
> reply-all from now on.

We just changed the list default to make it easier for people to filter
email and to have discussions on petsc-users without necessarily being
overwhelmed by all list traffic.  For example, "subscribe without
delivery" works properly now.  Discussed at length starting here:

http://lists.mcs.anl.gov/pipermail/petsc-users/2013-April/017067.html

>>    This procedure may not work if U has multiple fields per mesh node
> right ? The field names are already set into Default section of the dm.

Yes, the name is a combination of the object name (the automatic name
was "Vec_0xyyyyyyyy"), the field name you give to DMPlex, and the
location (point/cell).

>   I set the field layout and boundary points using DMPlexCreateSection and
> DMSetDefualtSection
>   Now, my test problem has 567 nodes. Node 1 and 567 have Dirichlet BC.
> When i do DMGetGlobalVector it has size 565, the solution vector of the
> snes  also has size 565.  The solution vector written vtu file has 567
> values with zero value at the boundary nodes. Am i missing a step here?
>
> Usgin Vecsetvaluessection i apply bc  inside the subroutines passed to
> dmsnessetfunction/jacobain. The bc values are propagated to the solver.

I think Matt envisions running DMGlobalToLocalBegin/End yourself,
filling in those values, and then VecView on the local Vec.  I'm not
thrilled with using local vectors to represent global state, but it is
the first thing the implementation does when you give it a global
vector, so it's the right thing for you to do.


More information about the petsc-users mailing list