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