PetscHypotReal#

Returns the Euclidean distance sqrt(a*a + b*b) of two PetscReal values, without intermediate overflow

Synopsis#

#include <petscmath.h>
PetscReal PetscHypotReal(PetscReal a, PetscReal b)

Not Collective; No Fortran Support

Input Parameters#

  • a - the value

  • b - the value

See Also#

PetscReal, PetscScalar, PetscComplex

Level#

beginner

Location#

include/petscmath.h

Examples#

src/sys/tests/ex25.c
src/ksp/ksp/tutorials/ex90.c


Index of all Sys routines
Table of Contents for all manual pages
Index of all manual pages