xref: /petsc/src/snes/ftn-mod/petscsnes.h90 (revision 0337bfe0b9dcc77abc5d44df0b7f57cdcdf2ff74)
1#if defined(PETSC_HAVE_FORTRAN_TYPE_STAR)
2      Interface
3      subroutine DMDASNESSetFunctionLocal(dm,imode,func,ctx,ierr)
4      use, intrinsic :: ISO_C_binding
5      import tSNES,tDM,eInsertMode
6       DM, intent(in) :: dm
7       InsertMode, intent(in) :: imode
8       external :: func
9       type(*) :: ctx
10       PetscErrorCode, intent(out) :: ierr
11      end subroutine DMDASNESSetFunctionLocal
12      end Interface
13
14      Interface
15      subroutine DMSNESSetFunctionLocal(dm,func,ctx,ierr)
16      use, intrinsic :: ISO_C_binding
17      import tSNES,tDM
18       DM, intent(in) :: dm
19       external :: func
20       type(*)  :: ctx
21       PetscErrorCode, intent(out) :: ierr
22      end subroutine DMSNESSetFunctionLocal
23      end Interface
24
25      interface SNESSetFunction
26      subroutine SNESSetFunction(a,b,c,d,z)
27      use, intrinsic :: ISO_C_binding
28       import tSNES, tVec
29       SNES a
30       Vec b
31       external c
32       type(*) d
33       PetscErrorCode z
34      end subroutine
35      end Interface
36
37      interface SNESSetJacobian
38      subroutine SNESSetJacobian(a,b,c,d,e,z)
39      use, intrinsic :: ISO_C_binding
40       import tSNES, tMat
41       SNES a
42       Mat b
43       Mat c
44       external d
45       type(*) e
46       PetscErrorCode z
47      end subroutine
48      end Interface
49
50      interface SNESGetJacobian
51      subroutine SNESGetJacobian(a,b,c,d,e,z)
52      use, intrinsic :: ISO_C_binding
53       import tSNES, tMat
54       SNES a
55       Mat b
56       Mat c
57       external d
58       type(*) e
59       PetscErrorCode z
60      end subroutine
61      end Interface
62
63      Interface
64      subroutine DMSNESSetJacobianLocal(dm,func,ctx,ierr)
65      use, intrinsic :: ISO_C_binding
66      import tSNES,tDM
67       DM, intent(in) :: dm
68       external :: func
69       type(*)  :: ctx
70       PetscErrorCode, intent(out) :: ierr
71      end subroutine DMSNESSetJacobianLocal
72      end Interface
73
74      Interface
75      subroutine SNESSetConvergenceTest(snes,func,cctx,destroy,ierr)
76      use, intrinsic :: ISO_C_binding
77      import tSNES
78       SNES :: snes
79       external :: func
80       type(*) :: cctx
81       external :: destroy
82       PetscErrorCode, intent(out) :: ierr
83      end subroutine
84      end Interface
85#endif
86
87     Interface
88      subroutine SNESRestoreConvergenceHistory(snes,r,its,na,ierr)
89      use, intrinsic :: ISO_C_binding
90      import tSNES
91       SNES snes
92       PetscInt na
93       PetscReal, pointer :: r(:)
94       PetscInt, pointer :: its(:)
95       PetscErrorCode, intent(out) :: ierr
96      end subroutine
97      end Interface
98
99