petsc-3.12.1 2019-10-22
Report Typos and Errors

# PetscImaginaryPart

Returns the imaginary part of a PetscScalar

### Synopsis

    #include <petscmath.h>
    PetscReal PetscImaginaryPart(PetscScalar v)

Not Collective

### Input Parameter

v -value to find the imaginary part of

### Notes

If PETSc was configured for real numbers then this always returns the value 0

### See Also

PetscScalar, PetscRealPart(), PetscMax(), PetscClipInterval(), PetscAbsInt(), PetscAbsReal(), PetscSqr()

### Level

beginner

### Location

include/petscmath.h

### Examples

src/vec/vec/utils/tagger/examples/tutorials/ex1.c.html
src/dm/examples/tutorials/ex15.c.html
src/ksp/ksp/examples/tutorials/ex11.c.html
Index of all Sys routines
Table of Contents for all manual pages
Index of all manual pages