petsc-3.7.1 2016-05-15
Report Typos and Errors

# PetscInitializeFortran

Routine that should be called soon AFTER the call to PetscInitialize() if one is using a C main program that calls Fortran routines that in turn call PETSc routines.

### Synopsis

    PetscErrorCode PetscInitializeFortran(void)

Collective on PETSC_COMM_WORLD Many br

Many br

### Notes

PetscInitializeFortran() initializes some of the default viewers, Many brcommunicators, etc. for use in the Fortran if a user's main program is Many brwritten in C. PetscInitializeFortran() is NOT needed if a user's main Many brprogram is written in Fortran; in this case, just calling Many brPetscInitialize() in the main (Fortran) program is sufficient. Many br

### See Also

PetscInitialize()

### Keywords

Mixing C and Fortran, passing PETSc objects to Fortran

Level:beginner
Location:src/sys/objects/ftn-custom/zstartf.c
Index of all Sys routines
Table of Contents for all manual pages
Index of all manual pages

### Examples

src/vec/vec/examples/tutorials/ex7.c.html