[petsc-users] Back to struct in Fortran to represent field with dof > 1

Christophe Ortiz christophe.ortiz at ciemat.es
Tue Oct 1 07:32:20 CDT 2013

On Tue, Oct 1, 2013 at 2:01 PM, Jed Brown <jedbrown at mcs.anl.gov> wrote:

> Barry Smith <bsmith at mcs.anl.gov> writes:
> >    I put the example with VecGetArray() into petsc-dev and if you send
> >    me one with DMDAVecGetArray() I'll add that as well.  Since the
> >    derived type has to appear explicitly in the code I can't put
> >    something in the library only in examples that people can copy and
> >    change.
> This is the sad state of Fortran.  Alternatively, it should be possible
> to call the C DMDAVecGetArray via the ISO C bindings in Fortran 2003.
I will check that. I have the book fortran 95/2003 by Metcalf and there is
a chapter dedicated to iso c bindings.

> Yet another example that the best way to call Fortran libraries from
> Fortran is to use the ISO C bindings.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20131001/9d617e74/attachment.html>

More information about the petsc-users mailing list