locate2 Function

private function locate2(n, xx, x, eps)

Note

Function that returns the location of an element in a vector.

Given an array xx(1: n) , and given a value x , it returns a value j such that x is between xx( j ) and xx( j + 1 ).

xx must be monotonic, either increasing or decreasing. j = 0 or j = n is returned to indicate that x is out of range.

The difference with locate is the use of eps for comparisons of reals.

Arguments

Type IntentOptional Attributes Name
integer(kind=I4), intent(in) :: n

vector length

real(kind=R8), intent(in), dimension(1:n) :: xx

vector

real(kind=R8), intent(in) :: x

value to locate

real(kind=R8), intent(in) :: eps

small value for comparisons of reals

Return Value integer(kind=i4)


Called by

proc~~locate2~~CalledByGraph proc~locate2 locate2 proc~calcul_asfc_hermite calcul_asfc_hermite proc~calcul_asfc_hermite->proc~locate2 proc~calcul_asfc calcul_asfc proc~calcul_asfc->proc~calcul_asfc_hermite program~test_asfc test_asfc program~test_asfc->proc~calcul_asfc_hermite