Actual source code: petscmat.h90

      3: ! rename MAT_INFO_SIZE and MAT_FACTORINFO_SIZE to enable reuse here
      4: #define MAT_INFO_SIZE MAT_INFO_SIZE_MOD
      5: #define MAT_FACTORINFO_SIZE MAT_FACTORINFO_SIZE_MOD
      6:       Interface
      7:         Subroutine MatFDColoringGetPerturbedColumnsF90(i,array,ierr)
      8:           import tMatFDColoring
      9:           PetscInt, pointer :: array(:)
     10:           PetscErrorCode  ierr
     11:          MatFDColoring       i
     12:         End Subroutine
     13:       End Interface

     15:       Interface
     16:         Subroutine MatFDColoringRestorePerturbedColumnsF90(i,array,ierr)
     17:           import tMatFDColoring
     18:           PetscInt, pointer :: array(:)
     19:           PetscErrorCode ierr
     20:          MatFDColoring      i
     21:         End Subroutine
     22:       End Interface

     24:       Interface
     25:       subroutine MatCreateMPIAIJWithSplitArrays(a,b,c,d,e,f,g,h,i,j,k,l,&
     26:      &z)
     27:        import tMat
     28:        MPI_Comm a ! MPI_Comm
     29:        PetscInt b ! PetscInt
     30:        PetscInt c ! PetscInt
     31:        PetscInt d ! PetscInt
     32:        PetscInt e ! PetscInt
     33:        PetscInt f (*) ! PetscInt
     34:        PetscInt g (*) ! PetscInt
     35:        PetscScalar h (*) ! PetscScalar
     36:        PetscInt i (*) ! PetscInt
     37:        PetscInt j (*) ! PetscInt
     38:        PetscScalar k (*) ! PetscScalar
     39:        Mat l ! Mat
     40:        PetscErrorCode z
     41:        end subroutine
     42:       End Interface

     44:       interface MatNullSpaceCreate
     45:       subroutine MatNullSpaceCreate1(a,b,c,d,e,z)
     46:        import tVec,tMatNullSpace
     47:        MPI_Comm a
     48:        PetscBool b
     49:        PetscInt c
     50:        Vec d (*)
     51:        MatNullSpace e
     52:        PetscErrorCode z
     53:        end subroutine
     54:       subroutine MatNullSpaceCreate0(a,b,c,d,e,z)
     55:        import tVec,tMatNullSpace
     56:        MPI_Comm a
     57:        PetscBool b
     58:        PetscInt c
     59:        Vec d
     60:        MatNullSpace e
     61:        PetscErrorCode z
     62:        end subroutine
     63:       end interface

     65:       interface MatGetSize
     66:       subroutine MatGetSize00(a,b,c,z)
     67:        import tMat
     68:        Mat a
     69:        PetscInt b
     70:        PetscInt c
     71:        PetscErrorCode z
     72:        end subroutine
     73:       subroutine MatGetSize10(a,b,c,z)
     74:        import tMat
     75:        Mat a
     76:        PetscInt b(*)
     77:        PetscInt c
     78:        PetscErrorCode z
     79:        end subroutine
     80:       subroutine MatGetSize01(a,b,c,z)
     81:        import tMat
     82:        Mat a
     83:        PetscInt b
     84:        PetscInt c(*)
     85:        PetscErrorCode z
     86:        end subroutine
     87:       end interface

     89:       interface MatGetLocalSize
     90:       subroutine MatGetLocalSize00(a,b,c,z)
     91:        import tMat
     92:        Mat a
     93:        PetscInt b
     94:        PetscInt c
     95:        PetscErrorCode z
     96:        end subroutine
     97:       subroutine MatGetLocalSize10(a,b,c,z)
     98:        import tMat
     99:        Mat a
    100:        PetscInt b(*)
    101:        PetscInt c
    102:        PetscErrorCode z
    103:        end subroutine
    104:       subroutine MatGetLocalSize01(a,b,c,z)
    105:        import tMat
    106:        Mat a
    107:        PetscInt b
    108:        PetscInt c(*)
    109:        PetscErrorCode z
    110:        end subroutine
    111:        end interface

    113:         Interface
    114:         subroutine MatCreateAIJ(a,b,c,d,e,f,g,h,i,j,z)
    115:           import tMat
    116:           MPI_Comm a
    117:           PetscInt b
    118:           PetscInt c
    119:           PetscInt d
    120:           PetscInt e
    121:           PetscInt f
    122:           PetscInt g (*)
    123:           PetscInt h
    124:           PetscInt i (*)
    125:           Mat j
    126:           PetscErrorCode z
    127:         end subroutine

    129:         subroutine MatCreateSeqAIJ(a,b,c,d,e,f,z)
    130:           import tMat
    131:           MPI_Comm a
    132:           PetscInt b
    133:           PetscInt c
    134:           PetscInt d
    135:           PetscInt e(*)
    136:           Mat f
    137:           PetscErrorCode z
    138:         end subroutine

    140:         subroutine MatSeqAIJSetPreallocation(a,b,c,z)
    141:           import tMat
    142:           Mat a
    143:           PetscInt b
    144:           PetscInt c(*)
    145:           PetscErrorCode z
    146:         end subroutine

    148:         subroutine MatSeqBAIJSetPreallocation(a,b,c,d,z)
    149:           import tMat
    150:           Mat a
    151:           PetscInt b,c
    152:           PetscInt d(*)
    153:           PetscErrorCode z
    154:         end subroutine

    156:         subroutine MatMPIAIJSetPreallocation(a,b,c,d,e,z)
    157:           import tMat
    158:           Mat a
    159:           PetscInt b
    160:           PetscInt c(*)
    161:           PetscInt d
    162:           PetscInt e(*)
    163:           PetscErrorCode z
    164:         end subroutine

    166:         subroutine MatXAIJSetPreallocationb(a,b,c,d,e,f,z)
    167:           import tMat
    168:           Mat a ! Mat
    169:           PetscInt b ! PetscInt
    170:           PetscInt c (*) ! PetscInt
    171:           PetscInt d (*) ! PetscInt
    172:           PetscInt e (*) ! PetscInt
    173:           PetscInt f (*) ! PetscInt
    174:           PetscErrorCode z
    175:         end subroutine

    177:         subroutine MatSetValue(myMat,i,j,va,mode,ierr)
    178:           import tMat
    179:           Mat :: myMat
    180:           PetscInt :: i,j
    181:           PetscScalar :: va
    182:           InsertMode :: mode
    183:           PetscErrorCode, intent(out) :: ierr
    184:         end subroutine

    186:         subroutine MatSetValueLocal(myMat,i,j,va,mode,ierr)
    187:           import tMat
    188:           Mat :: myMat
    189:           PetscInt :: i,j
    190:           PetscScalar :: va
    191:           InsertMode :: mode
    192:           PetscErrorCode, intent(out) :: ierr
    193:         end subroutine

    195:         end interface

    197:         Interface MatGetValues
    198:         ! picky Fortran requires separate prototypes if args
    199:         ! are arrays or scalars
    200:         subroutine MatGetValues0(a,b,c,d,e,f,z)
    201:           import tMat
    202:           Mat a ! Mat
    203:           PetscInt b ! PetscInt
    204:           PetscInt c (*) ! PetscInt
    205:           PetscInt d ! PetscInt
    206:           PetscInt e (*) ! PetscInt
    207:           PetscScalar f (*) ! PetscScalar
    208:           PetscErrorCode z
    209:         end subroutine
    210:         subroutine MatGetValuesnn1(a,b,c,d,e,f,z)
    211:           import tMat
    212:           Mat a ! Mat
    213:           PetscInt b ! PetscInt
    214:           PetscInt c (*) ! PetscInt
    215:           PetscInt d ! PetscInt
    216:           PetscInt e (*) ! PetscInt
    217:           PetscScalar f  ! PetscScalar
    218:           PetscErrorCode z
    219:         end subroutine
    220:         subroutine MatGetValuesnnnn(a,b,c,d,e,f,z)
    221:           import tMat
    222:           Mat a ! Mat
    223:           PetscInt b ! PetscInt
    224:           PetscInt c (*) ! PetscInt
    225:           PetscInt d ! PetscInt
    226:           PetscInt e (*) ! PetscInt
    227:           PetscScalar f(1,1)  ! PetscScalar
    228:           PetscErrorCode z
    229:         end subroutine
    230:         subroutine MatGetValues11(a,b,c,d,e,f,z)
    231:           import tMat
    232:           Mat a ! Mat
    233:           PetscInt b ! PetscInt
    234:           PetscInt c ! PetscInt
    235:           PetscInt d ! PetscInt
    236:           PetscInt e ! PetscInt
    237:           PetscScalar f  ! PetscScalar
    238:           PetscErrorCode z
    239:         end subroutine
    240:         subroutine MatGetValues1n(a,b,c,d,e,f,z)
    241:           import tMat
    242:           Mat a ! Mat
    243:           PetscInt b ! PetscInt
    244:           PetscInt c ! PetscInt
    245:           PetscInt d ! PetscInt
    246:           PetscInt e (*) ! PetscInt
    247:           PetscScalar f (*)  ! PetscScalar
    248:           PetscErrorCode z
    249:         end subroutine
    250:         subroutine MatGetValuesn1(a,b,c,d,e,f,z)
    251:           import tMat
    252:           Mat a ! Mat
    253:           PetscInt b ! PetscInt
    254:           PetscInt c (*) ! PetscInt
    255:           PetscInt d ! PetscInt
    256:           PetscInt e ! PetscInt
    257:           PetscScalar f (*) ! PetscScalar
    258:           PetscErrorCode z
    259:         end subroutine
    260:       End Interface MatGetValues

    263:         Interface MatSetValues
    264:         ! picky Fortran requires separate prototypes if args
    265:         ! are arrays or scalars
    266:         subroutine MatSetValues0(a,b,c,d,e,f,g,z)
    267:           import tMat
    268:           Mat a ! Mat
    269:           PetscInt b ! PetscInt
    270:           PetscInt c (*) ! PetscInt
    271:           PetscInt d ! PetscInt
    272:           PetscInt e (*) ! PetscInt
    273:           PetscScalar f (*) ! PetscScalar
    274:           InsertMode g ! InsertMode
    275:           PetscErrorCode z
    276:         end subroutine
    277:         subroutine MatSetValuesnn1(a,b,c,d,e,f,g,z)
    278:           import tMat
    279:           Mat a ! Mat
    280:           PetscInt b ! PetscInt
    281:           PetscInt c (*) ! PetscInt
    282:           PetscInt d ! PetscInt
    283:           PetscInt e (*) ! PetscInt
    284:           PetscScalar f  ! PetscScalar
    285:           InsertMode g ! InsertMode
    286:           PetscErrorCode z
    287:         end subroutine
    288:         subroutine MatSetValuesnnnn(a,b,c,d,e,f,g,z)
    289:           import tMat
    290:           Mat a ! Mat
    291:           PetscInt b ! PetscInt
    292:           PetscInt c (*) ! PetscInt
    293:           PetscInt d ! PetscInt
    294:           PetscInt e (*) ! PetscInt
    295:           PetscScalar f(1,1)  ! PetscScalar
    296:           InsertMode g ! InsertMode
    297:           PetscErrorCode z
    298:         end subroutine
    299:         subroutine MatSetValues11(a,b,c,d,e,f,g,z)
    300:           import tMat
    301:           Mat a ! Mat
    302:           PetscInt b ! PetscInt
    303:           PetscInt c ! PetscInt
    304:           PetscInt d ! PetscInt
    305:           PetscInt e ! PetscInt
    306:           PetscScalar f  ! PetscScalar
    307:           InsertMode g ! InsertMode
    308:           PetscErrorCode z
    309:         end subroutine
    310:         subroutine MatSetValues1n(a,b,c,d,e,f,g,z)
    311:           import tMat
    312:           Mat a ! Mat
    313:           PetscInt b ! PetscInt
    314:           PetscInt c ! PetscInt
    315:           PetscInt d ! PetscInt
    316:           PetscInt e (*) ! PetscInt
    317:           PetscScalar f (*)  ! PetscScalar
    318:           InsertMode g ! InsertMode
    319:           PetscErrorCode z
    320:         end subroutine
    321:         subroutine MatSetValuesn1(a,b,c,d,e,f,g,z)
    322:           import tMat
    323:           Mat a ! Mat
    324:           PetscInt b ! PetscInt
    325:           PetscInt c (*) ! PetscInt
    326:           PetscInt d ! PetscInt
    327:           PetscInt e ! PetscInt
    328:           PetscScalar f (*) ! PetscScalar
    329:           InsertMode g ! InsertMode
    330:           PetscErrorCode z
    331:         end subroutine
    332:       End Interface MatSetValues

    334:       Interface MatSetValuesLocal
    335:         ! picky Fortran requires separate prototypes if args
    336:         ! are arrays or scalars
    337:         subroutine MatSetValuesLocal0(a,b,c,d,e,f,g,z)
    338:           import tMat
    339:           Mat a ! Mat
    340:           PetscInt b ! PetscInt
    341:           PetscInt c (*) ! PetscInt
    342:           PetscInt d ! PetscInt
    343:           PetscInt e (*) ! PetscInt
    344:           PetscScalar f (*) ! PetscScalar
    345:           InsertMode g ! InsertMode
    346:           PetscErrorCode z
    347:         end subroutine
    348:         subroutine MatSetValuesLocal11(a,b,c,d,e,f,g,z)
    349:           import tMat
    350:           Mat a ! Mat
    351:           PetscInt b ! PetscInt
    352:           PetscInt c ! PetscInt
    353:           PetscInt d ! PetscInt
    354:           PetscInt e ! PetscInt
    355:           PetscScalar f(*)  ! PetscScalar
    356:           InsertMode g ! InsertMode
    357:           PetscErrorCode z
    358:         end subroutine
    359:         subroutine MatSetValuesLocal11nn(a,b,c,d,e,f,g,z)
    360:           import tMat
    361:           Mat a ! Mat
    362:           PetscInt b ! PetscInt
    363:           PetscInt c ! PetscInt
    364:           PetscInt d ! PetscInt
    365:           PetscInt e ! PetscInt
    366:           PetscScalar f(1,1)  ! PetscScalar
    367:           InsertMode g ! InsertMode
    368:           PetscErrorCode z
    369:         end subroutine
    370:         subroutine MatSetValuesLocal111(a,b,c,d,e,f,g,z)
    371:           import tMat
    372:           Mat a ! Mat
    373:           PetscInt b ! PetscInt
    374:           PetscInt c ! PetscInt
    375:           PetscInt d ! PetscInt
    376:           PetscInt e ! PetscInt
    377:           PetscScalar f  ! PetscScalar
    378:           InsertMode g ! InsertMode
    379:           PetscErrorCode z
    380:         end subroutine
    381:         subroutine MatSetValuesLocal1n(a,b,c,d,e,f,g,z)
    382:           import tMat
    383:           Mat a ! Mat
    384:           PetscInt b ! PetscInt
    385:           PetscInt c ! PetscInt
    386:           PetscInt d ! PetscInt
    387:           PetscInt e (*) ! PetscInt
    388:           PetscScalar f (*)  ! PetscScalar
    389:           InsertMode g ! InsertMode
    390:           PetscErrorCode z
    391:         end subroutine
    392:         subroutine MatSetValuesLocaln1(a,b,c,d,e,f,g,z)
    393:           import tMat
    394:           Mat a ! Mat
    395:           PetscInt b ! PetscInt
    396:           PetscInt c (*) ! PetscInt
    397:           PetscInt d ! PetscInt
    398:           PetscInt e ! PetscInt
    399:           PetscScalar f (*) ! PetscScalar
    400:           InsertMode g ! InsertMode
    401:           PetscErrorCode z
    402:         end subroutine
    403:       End Interface MatSetValuesLocal

    405:       Interface MatSetValuesBlockedLocal
    406:         ! picky Fortran requires separate prototypes if args
    407:         ! are arrays or scalars
    408:         subroutine MatSetValuesBlockedLocal0(a,b,c,d,e,f,g,z)
    409:           import tMat
    410:           Mat a ! Mat
    411:           PetscInt b ! PetscInt
    412:           PetscInt c (*) ! PetscInt
    413:           PetscInt d ! PetscInt
    414:           PetscInt e (*) ! PetscInt
    415:           PetscScalar f (*) ! PetscScalar
    416:           InsertMode g ! InsertMode
    417:           PetscErrorCode z
    418:         end subroutine
    419:         subroutine MatSetValuesBlockedLocal11(a,b,c,d,e,f,g,z)
    420:           import tMat
    421:           Mat a ! Mat
    422:           PetscInt b ! PetscInt
    423:           PetscInt c ! PetscInt
    424:           PetscInt d ! PetscInt
    425:           PetscInt e ! PetscInt
    426:           PetscScalar f(*)  ! PetscScalar
    427:           InsertMode g ! InsertMode
    428:           PetscErrorCode z
    429:         end subroutine
    430:         subroutine MatSetValuesBlockedLocal111(a,b,c,d,e,f,g,z)
    431:           import tMat
    432:           Mat a ! Mat
    433:           PetscInt b ! PetscInt
    434:           PetscInt c ! PetscInt
    435:           PetscInt d ! PetscInt
    436:           PetscInt e ! PetscInt
    437:           PetscScalar f(1,1)  ! PetscScalar
    438:           InsertMode g ! InsertMode
    439:           PetscErrorCode z
    440:         end subroutine
    441:         subroutine MatSetValuesBlockedLocal1n(a,b,c,d,e,f,g,z)
    442:           import tMat
    443:           Mat a ! Mat
    444:           PetscInt b ! PetscInt
    445:           PetscInt c ! PetscInt
    446:           PetscInt d ! PetscInt
    447:           PetscInt e (*) ! PetscInt
    448:           PetscScalar f (*)  ! PetscScalar
    449:           InsertMode g ! InsertMode
    450:           PetscErrorCode z
    451:         end subroutine
    452:         subroutine MatSetValuesBlockedLocaln1(a,b,c,d,e,f,g,z)
    453:           import tMat
    454:           Mat a ! Mat
    455:           PetscInt b ! PetscInt
    456:           PetscInt c (*) ! PetscInt
    457:           PetscInt d ! PetscInt
    458:           PetscInt e ! PetscInt
    459:           PetscScalar f (*) ! PetscScalar
    460:           InsertMode g ! InsertMode
    461:           PetscErrorCode z
    462:         end subroutine
    463:       End Interface MatSetValuesBlockedLocal

    465:       Interface MatSetValuesBlocked
    466:         ! picky Fortran requires separate prototypes if args
    467:         ! are arrays or scalars
    468:         subroutine MatSetValuesBlocked2(a,b,c,d,e,f,g,z)
    469:           import tMat
    470:           Mat a ! Mat
    471:           PetscInt b ! PetscInt
    472:           PetscInt c (*) ! PetscInt
    473:           PetscInt d ! PetscInt
    474:           PetscInt e (*) ! PetscInt
    475:           PetscScalar, pointer :: f (:,:)
    476:           InsertMode g ! InsertMode
    477:           PetscErrorCode z
    478:         end subroutine
    479:         subroutine MatSetValuesBlocked0(a,b,c,d,e,f,g,z)
    480:           import tMat
    481:           Mat a ! Mat
    482:           PetscInt b ! PetscInt
    483:           PetscInt c (*) ! PetscInt
    484:           PetscInt d ! PetscInt
    485:           PetscInt e (*) ! PetscInt
    486:           PetscScalar f (*) ! PetscScalar
    487:           InsertMode g ! InsertMode
    488:           PetscErrorCode z
    489:         end subroutine
    490:         subroutine MatSetValuesBlocked11(a,b,c,d,e,f,g,z)
    491:           import tMat
    492:           Mat a ! Mat
    493:           PetscInt b ! PetscInt
    494:           PetscInt c ! PetscInt
    495:           PetscInt d ! PetscInt
    496:           PetscInt e ! PetscInt
    497:           PetscScalar f(*)  ! PetscScalar
    498:           InsertMode g ! InsertMode
    499:           PetscErrorCode z
    500:         end subroutine
    501:         subroutine MatSetValuesBlocked111(a,b,c,d,e,f,g,z)
    502:           import tMat
    503:           Mat a ! Mat
    504:           PetscInt b ! PetscInt
    505:           PetscInt c ! PetscInt
    506:           PetscInt d ! PetscInt
    507:           PetscInt e ! PetscInt
    508:           PetscScalar f(1,1)  ! PetscScalar
    509:           InsertMode g ! InsertMode
    510:           PetscErrorCode z
    511:         end subroutine
    512:         subroutine MatSetValuesBlocked1n(a,b,c,d,e,f,g,z)
    513:           import tMat
    514:           Mat a ! Mat
    515:           PetscInt b ! PetscInt
    516:           PetscInt c ! PetscInt
    517:           PetscInt d ! PetscInt
    518:           PetscInt e (*) ! PetscInt
    519:           PetscScalar f (*)  ! PetscScalar
    520:           InsertMode g ! InsertMode
    521:           PetscErrorCode z
    522:         end subroutine
    523:         subroutine MatSetValuesBlockedn1(a,b,c,d,e,f,g,z)
    524:           import tMat
    525:           Mat a ! Mat
    526:           PetscInt b ! PetscInt
    527:           PetscInt c (*) ! PetscInt
    528:           PetscInt d ! PetscInt
    529:           PetscInt e ! PetscInt
    530:           PetscScalar f (*) ! PetscScalar
    531:           InsertMode g ! InsertMode
    532:           PetscErrorCode z
    533:         end subroutine
    534:       End Interface MatSetValuesBlocked

    536:       Interface
    537:         Subroutine MatGetRow(v,row,ncols,cols,vals,ierr)
    538:           import tMat
    539:           PetscInt cols(*)
    540:           PetscInt  row,ncols
    541:           PetscScalar vals(*)
    542:           PetscErrorCode ierr
    543:           Mat     v
    544:         End Subroutine
    545:       End Interface

    547:       Interface
    548:         Subroutine MatRestoreRow(v,row,ncols,cols,vals,ierr)
    549:           import tMat
    550:           PetscInt  cols(*)
    551:           PetscInt  row,ncols
    552:           PetscScalar vals(*)
    553:           PetscErrorCode ierr
    554:           Mat     v
    555:         End Subroutine
    556:       End Interface

    558:       Interface
    559:         Subroutine MatGetRowIJF90(v,sh,sym,bl,n,ia,ja,d,ierr)
    560:           import tMat
    561:           PetscInt, pointer :: ia(:), ja(:)
    562:           PetscInt  n,sh
    563:           PetscBool  sym,bl,d
    564:           PetscErrorCode ierr
    565:           Mat     v
    566:         End Subroutine
    567:       End Interface

    569:       Interface
    570:         Subroutine MatRestoreRowIJF90(v,s,sy,b,n,ia,ja,d,ierr)
    571:           import tMat
    572:           PetscInt, pointer :: ia(:), ja(:)
    573:           PetscInt  n,s
    574:           PetscBool  sy,b,d
    575:           PetscErrorCode ierr
    576:           Mat     v
    577:         End Subroutine
    578:       End Interface

    580:       Interface
    581:         Subroutine MatDenseGetArrayF90(v,array,ierr)
    582:           import tMat
    583:           PetscScalar, pointer :: array(:,:)
    584:           PetscErrorCode ierr
    585:           Mat     v
    586:         End Subroutine
    587:       End Interface

    589:       Interface
    590:         Subroutine MatDenseRestoreArrayF90(v,array,ierr)
    591:           import tMat
    592:           PetscScalar, pointer :: array(:,:)
    593:           PetscErrorCode ierr
    594:           Mat     v
    595:         End Subroutine
    596:       End Interface

    598:       Interface
    599:         Subroutine MatDenseGetColumnF90(v,col,array,ierr)
    600:           import tMat
    601:           PetscScalar, pointer :: array(:)
    602:           PetscErrorCode ierr
    603:           Mat     v
    604:           PetscInt col
    605:         End Subroutine
    606:       End Interface

    608:       Interface
    609:         Subroutine MatDenseRestoreColumnF90(v,array,ierr)
    610:           import tMat
    611:           PetscScalar, pointer :: array(:)
    612:           PetscErrorCode ierr
    613:           Mat     v
    614:         End Subroutine
    615:       End Interface

    617:       Interface
    618:         Subroutine MatSeqAIJGetArrayF90(v,array,ierr)
    619:           import tMat
    620:           PetscScalar, pointer :: array(:)
    621:           PetscErrorCode ierr
    622:           Mat     v
    623:         End Subroutine
    624:       End Interface

    627:       Interface
    628:         Subroutine MatSeqAIJRestoreArrayF90(v,array,ierr)
    629:           import tMat
    630:           PetscScalar, pointer :: array(:)
    631:           PetscErrorCode ierr
    632:           Mat     v
    633:         End Subroutine
    634:       End Interface

    636:       Interface
    637:         Subroutine MatGetGhostsF90(v,array,ierr)
    638:           import tMat
    639:           PetscInt, pointer :: array(:)
    640:           PetscErrorCode ierr
    641:           Mat     v
    642:         End Subroutine
    643:       End Interface

    645:       Interface
    646:          Subroutine MatGetInfo(v, flag, info ,ierr)
    647:          import tMat
    648:          Mat  v
    649:          MatInfoType flag
    650: #include "../src/mat/f90-mod/petscmatinfosize.h"
    651:          MatInfo info(MAT_INFO_SIZE)
    652:          PetscErrorCode ierr
    653:        End Subroutine
    654:       End Interface

    656:       Interface
    657:          subroutine MatLUFactor(v, row, col, info ,ierr)
    658:          import tMat,tIS
    659:          Mat  v
    660:          IS row
    661:          IS col
    662: #include "../src/mat/f90-mod/petscmatfactorinfosize.h"
    663:          MatFactorInfo info(MAT_FACTORINFO_SIZE)
    664:          PetscErrorCode ierr
    665:          end subroutine
    666:       End Interface

    668:       Interface
    669:          subroutine MatILUFactor(v, row, col, info ,ierr)
    670:          import tMat,tIS
    671:          Mat  v
    672:          IS row
    673:          IS col
    674: #include "../src/mat/f90-mod/petscmatfactorinfosize.h"
    675:          MatFactorInfo info(MAT_FACTORINFO_SIZE)
    676:          PetscErrorCode ierr
    677:          end subroutine
    678:       End Interface

    680:       Interface
    681:          subroutine MatLUFactorSymbolic(fact, v, row, col, info ,ierr)
    682:          import tMat,tIS
    683:          Mat  fact
    684:          Mat  v
    685:          IS row
    686:          IS col
    687: #include "../src/mat/f90-mod/petscmatfactorinfosize.h"
    688:          MatFactorInfo info(MAT_FACTORINFO_SIZE)
    689:          PetscErrorCode ierr
    690:          end subroutine
    691:       End Interface

    693:       Interface
    694:          subroutine MatLUFactorNumeric(fact, v, info ,ierr)
    695:          import tMat
    696:          Mat  fact
    697:          Mat  v
    698: #include "../src/mat/f90-mod/petscmatfactorinfosize.h"
    699:          MatFactorInfo info(MAT_FACTORINFO_SIZE)
    700:          PetscErrorCode ierr
    701:          end subroutine
    702:       End Interface

    704:       Interface
    705:          subroutine MatCholeskyFactor(v, perm, info ,ierr)
    706:          import tMat,tIS
    707:          Mat  v
    708:          IS perm
    709: #include "../src/mat/f90-mod/petscmatfactorinfosize.h"
    710:          MatFactorInfo info(MAT_FACTORINFO_SIZE)
    711:          PetscErrorCode ierr
    712:          end subroutine
    713:       End Interface

    715:       Interface
    716:          subroutine MatCholeskyFactorSymbolic(fact,v,perm,info,ierr)
    717:          import tMat,tIS
    718:          Mat  fact
    719:          Mat  v
    720:          IS perm
    721: #include "../src/mat/f90-mod/petscmatfactorinfosize.h"
    722:          MatFactorInfo info(MAT_FACTORINFO_SIZE)
    723:          PetscErrorCode ierr
    724:          end subroutine
    725:       End Interface

    727:       Interface
    728:          subroutine MatCholeskyFactorNumeric(fact, v, info ,ierr)
    729:          import tMat
    730:          Mat  fact
    731:          Mat  v
    732: #include "../src/mat/f90-mod/petscmatfactorinfosize.h"
    733:          MatFactorInfo info(MAT_FACTORINFO_SIZE)
    734:          PetscErrorCode ierr
    735:          end subroutine
    736:       End Interface

    738:       Interface
    739:          subroutine MatILUFactorSymbolic(fact,v,row,col,info,ierr)
    740:          import tMat,tIS
    741:          Mat  fact
    742:          Mat  v
    743:          IS row
    744:          IS col
    745: #include "../src/mat/f90-mod/petscmatfactorinfosize.h"
    746:          MatFactorInfo info(MAT_FACTORINFO_SIZE)
    747:          PetscErrorCode ierr
    748:          end subroutine
    749:       End Interface

    751:       Interface
    752:          subroutine MatICCFactorSymbolic(fact, v, perm, info ,ierr)
    753:          import tMat,tIS
    754:          Mat  fact
    755:          Mat  v
    756:          IS perm
    757: #include "../src/mat/f90-mod/petscmatfactorinfosize.h"
    758:          MatFactorInfo info(MAT_FACTORINFO_SIZE)
    759:          PetscErrorCode ierr
    760:          end subroutine
    761:       End Interface

    763:       Interface
    764:          subroutine MatICCFactor(v, row, info ,ierr)
    765:          import tMat,tIS
    766:          Mat  v
    767:          IS row
    768: #include "../src/mat/f90-mod/petscmatfactorinfosize.h"
    769:          MatFactorInfo info(MAT_FACTORINFO_SIZE)
    770:          PetscErrorCode ierr
    771:          end subroutine
    772:       End Interface

    774:       Interface
    775:          subroutine MatGetGetNullSpace(A,n,ierr)
    776:          import tMat,tMatNullSpace
    777:          Mat  A
    778:          MatNullSpace n
    779:          PetscErrorCode ierr
    780:          end subroutine
    781:       End Interface

    783:       Interface
    784:          subroutine MatFactorInfoInitialize(info ,ierr)
    785: #include "../src/mat/f90-mod/petscmatfactorinfosize.h"
    786:          MatFactorInfo info(MAT_FACTORINFO_SIZE)
    787:          PetscErrorCode ierr
    788:          end subroutine
    789:       End Interface

    791:       Interface
    792:       subroutine MatSetType(a,b,z)
    793:       import tMat
    794:        Mat a
    795:        character(*) b
    796:        PetscErrorCode z
    797:        end subroutine
    798:       end Interface

    800:       Interface
    801:       subroutine MatView(a,b,z)
    802:       import tMat,tPetscViewer
    803:        Mat a
    804:        PetscViewer b
    805:        PetscErrorCode z
    806:        end subroutine
    807:       end Interface

    809:       Interface MatZeroRowsLocal
    810:       subroutine MatZeroRowsLocal0(a,b,c,d,e,f,z)
    811:       import tMat,tVec
    812:        Mat a ! Mat
    813:        PetscInt b ! PetscInt
    814:        PetscInt c (*) ! PetscInt
    815:        PetscScalar d ! PetscScalar
    816:        Vec e ! Vec
    817:        Vec f ! Vec
    818:        PetscErrorCode z
    819:        end subroutine
    820:       subroutine MatZeroRowsLocal1(a,b,c,d,e,f,z)
    821:       import tMat,tVec
    822:        Mat a ! Mat
    823:        PetscInt b ! PetscInt
    824:        PetscInt c ! PetscInt
    825:        PetscScalar d ! PetscScalar
    826:        Vec e ! Vec
    827:        Vec f ! Vec
    828:        PetscErrorCode z
    829:        end subroutine
    830:       End Interface

    832:       interface MatGetOwnershipRange
    833:       subroutine MatGetOwnershipRange00(a,b,c,ierr)
    834:        import tMat
    835:        Mat,intent(in) :: a ! Mat
    836:        PetscInt :: b,c ! PetscInt
    837:        PetscErrorCode,intent(out) :: ierr
    838:       end subroutine
    839:       subroutine MatGetOwnershipRange10(a,b,c,ierr)
    840:        import tMat
    841:        Mat,intent(in) :: a ! Mat
    842:        PetscInt,dimension(:) :: b ! PetscInt
    843:        PetscInt              :: c ! PetscInt
    844:        PetscErrorCode,intent(out) :: ierr
    845:       end subroutine
    846:       subroutine MatGetOwnershipRange01(a,b,c,ierr)
    847:        import tMat
    848:        Mat,intent(in) :: a ! Mat
    849:        PetscInt              :: b ! PetscInt
    850:        PetscInt,dimension(:) :: c ! PetscInt
    851:        PetscErrorCode,intent(out) :: ierr
    852:       end subroutine
    853:       subroutine MatGetOwnershipRange11(a,b,c,ierr)
    854:        import tMat
    855:        Mat,intent(in) :: a ! Mat
    856:        PetscInt,dimension(:) :: b,c ! PetscInt
    857:        PetscErrorCode,intent(out) :: ierr
    858:       end subroutine
    859:       end interface

    861:       interface
    862:       subroutine MatGetFactor(m,t,ft,f,ierr)
    863:       import tMat
    864:        Mat, intent(in) ::  m
    865:        character(*), intent(in) :: t
    866:        MatFactorType,intent(in) :: ft
    867:        Mat, intent(out) ::  f
    868:        PetscErrorCode,intent(out) :: ierr
    869:       end subroutine

    871:       subroutine MatPartitioningCreate(a,b,ierr)
    872:        MPI_Comm, intent(in) :: a ! MPI_comm
    873:        MatPartitioning, intent(out) ::  b
    874:        PetscErrorCode,intent(out) :: ierr
    875:       end subroutine

    877:       subroutine MatPartitioningDestroy(a,ierr)
    878:        MatPartitioning, intent(in) ::  a
    879:        PetscErrorCode,intent(out) :: ierr
    880:       end subroutine

    882:       subroutine MatPartitioningSetAdjacency(a,b,ierr)
    883:       import tMat
    884:        MatPartitioning, intent(in) ::  a
    885:        Mat, intent(in) ::  b
    886:        PetscErrorCode,intent(out) :: ierr
    887:       end subroutine

    889:       subroutine MatPartitioningSetFromOptions(a,ierr)
    890:        MatPartitioning, intent(in) ::  a
    891:        PetscErrorCode,intent(out) :: ierr
    892:       end subroutine

    894:       subroutine MatPartitioningApply(a,b,ierr)
    895:        import tIS
    896:        MatPartitioning, intent(in) ::  a
    897:        IS, intent(out) :: b
    898:        PetscErrorCode :: ierr
    899:       end subroutine

    901:       end interface

    903: ! revert MAT_INFO_SIZE and MAT_FACTORINFO_SIZE defines
    904: #undef MAT_INFO_SIZE
    905: #undef MAT_FACTORINFO_SIZE