petsc-3.4.2 2013-07-02

# PETSC_i

the imaginary number i

### Synopsis

    #define PETSC_DESIRE_COMPLEX
    #include <petscsys.h>
    PetscComplex PETSC_i;

### Note

Complex numbers are automatically available if PETSc was configured --with-scalar-type=complex (in which case PetscComplex will match PetscScalar), otherwise the macro PETSC_DESIRE_COMPLEX must be defined before including any PETSc headers. If the compiler supports complex numbers, PetscComplex and associated variables and functions will be defined and PETSC_HAVE_COMPLEX will be set.

### See Also

PetscRealPart(), PetscImaginaryPart(), PetscRealPartComplex(), PetscImaginaryPartComplex()

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

### Examples

src/ksp/ksp/examples/tutorials/ex11.c.html
src/ksp/ksp/examples/tutorials/ex39.c.html
src/ksp/ksp/examples/tutorials/ex40.c.html
src/ksp/ksp/examples/tutorials/ex11f.F.html