[petsc-users] Fortran problem MatGetValuesLocal

Mark Adams mfadams at lbl.gov
Tue Nov 28 08:33:40 CST 2023


It looks like we don't have a Fortran interface for this. In the
source code:

2366:   Developer Note:2367:   This is labeled with C so does not
automatically generate Fortran stubs and interfaces2368:   because it
requires multiple Fortran interfaces depending on which arguments are
scalar or arrays.

Someone else might be able to offer a workaround.

Thanks,
Mark

On Tue, Nov 28, 2023 at 5:46 AM Frank Bramkamp <bramkamp at nsc.liu.se> wrote:

> Dear PETSc team,
>
>
> We are using the latest petsc version 3.20.1, intel compiler 2023,
> and we found the following problem:
>
> We want to call the function MatGetValuesLocal to extract a block
> sub-matrix
> from an assembled matrix (e.g. a 5x5 blocked sub matrix). We use the
> matrix format MatCreateBAIJ in parallel.
> In particular we try to call MatGetValuesLocal in Fortran.
>
> It seems that the linked does not find the subroutine MatGetValuesLocal.
> The subroutine MatGetValues seems to be fine.
> I guess that the fortran stubs/fortran interface is missing for this
> routine.
> On the documentation side, you also write a note for developers that the
> fortran stubs and interface
> Is not automatically generated for MatGetValuesLocal. So maybe that has
> been forgotten to do.
>
>
> Unfortunately I do not have any small test example, since we just
> incorporated the function call into our own software.
> Otherwise I would first have to set a small test example for the parallel
> case.
>
> I think there is also an include file where one can check the fortran
> interfaces ?!
> I forgot where to look this up.
>
>
> Greetings, Frank Bramkamp
>
>
>
>
>
>
>
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20231128/44c18926/attachment.html>


More information about the petsc-users mailing list