Function

vvnextafter(_:_:_:_:)

Calculates the next machine-representable value for each element in an array of double-precision values.

Declaration

Parameters

parameter 1

The output array, z.

parameter 2

The input array, y.

parameter 3

The direction array, x.

parameter 4

The number of elements in the arrays.

Discussion

Not all values can be represented as a floating-point value of a given precision. This function sets a value in z[i] that is either minimally larger than the value in y[i] (if x[i] is larger than y[i]) or minimally smaller than the value in y[i] (if x[i] is smaller than y[i]).

See Also

Array-Oriented Arithmetic and Auxiliary Functions

static func ceil<U>(U) -> [Double]

Returns the ceiling of each element in a vector of double-precision values.

static func ceil<U>(U) -> [Float]

Returns the ceiling of each element in a vector of single-precision values.

static func ceil<U, V>(U, result: inout V)

Calculates the ceiling of each element in a vector of double-precision values.

static func ceil<U, V>(U, result: inout V)

Calculates the ceiling of each element in a vector of single-precision values.

static func copysign<U, V>(magnitudes: U, signs: V) -> [Double]

Returns each single-precision element in the magnitudes vector, setting its sign to the corresponding elements in the signs vector.

static func copysign<U, V>(magnitudes: U, signs: V) -> [Float]

Returns each single-precision element in the magnitudes vector, setting its sign to the corresponding elements in the signs vector.

static func copysign<T, U, V>(magnitudes: T, signs: U, result: inout V)

Calculates each double-precision element in the magnitudes vector, setting its sign to the corresponding elements in the signs vector.

static func copysign<T, U, V>(magnitudes: T, signs: U, result: inout V)

Calculates each single-precision element in the magnitudes vector, setting its sign to the corresponding elements in the signs vector.

static func floor<U>(U) -> [Double]

Returns the floor of each element in a vector of double-precision values.

static func floor<U>(U) -> [Float]

Returns the floor of each element in a vector of single-precision values.

static func floor<U, V>(U, result: inout V)

Calculates the floor of each element in a vector of double-precision values.

static func floor<U, V>(U, result: inout V)

Calculates the floor of each element in a vector of single-precision values.

static func nearestInteger<U>(U) -> [Double]

Returns the nearest integer to each element in a vector of double-precision values.

static func nearestInteger<U>(U) -> [Float]

Returns the nearest integer to each element in a vector of single-precision values.

static func nearestInteger<U, V>(U, result: inout V)

Calculates the nearest integer to each element in a vector of double-precision values.

static func nearestInteger<U, V>(U, result: inout V)

Calculates the nearest integer to each element in a vector of double-precision values.

static func reciprocal<U>(U) -> [Double]

Returns the reciprocal of each element in a vector of double-precision values.

static func reciprocal<U>(U) -> [Float]

Returns the reciprocal of each element in a vector of single-precision values.

static func reciprocal<U, V>(U, result: inout V)

Calculates the reciprocal of each element in a vector of double-precision values.

static func reciprocal<U, V>(U, result: inout V)

Calculates the reciprocal of each element in a vector of single-precision values.

static func remainder<U, V>(dividends: U, divisors: V) -> [Double]

Returns the remainder of the double-precision elements in dividends divided by the elements in divisors, using truncating division.

static func remainder<U, V>(dividends: U, divisors: V) -> [Float]

Returns the remainder of the single-precision elements in dividends divided by the elements in divisors, using truncating division.

static func remainder<T, U, V>(dividends: T, divisors: U, result: inout V)

Calculates the remainder of the double-precision elements in dividends divided by the elements in divisors, using truncating division.

static func remainder<T, U, V>(dividends: T, divisors: U, result: inout V)

Calculates the remainder of the single-precision elements in dividends divided by the elements in divisors, using truncating division.

static func rsqrt<U>(U) -> [Double]

Returns the reciprocal square root of each element in a vector of double-precision values.

static func rsqrt<U>(U) -> [Float]

Returns the reciprocal square root of each element in a vector of single-precision values.

static func rsqrt<U, V>(U, result: inout V)

Calculates the reciprocal square root of each element in a vector of double-precision values.

static func rsqrt<U, V>(U, result: inout V)

Calculates the reciprocal square root of each element in a vector of single-precision values.

static func sqrt<U>(U) -> [Double]

Returns the square root of each element in a vector of double-precision values.

static func sqrt<U>(U) -> [Float]

Returns the square root each element in a vector of single-precision values.

static func sqrt<U, V>(U, result: inout V)

Calculates the square root of each element in a vector of double-precision values.

static func sqrt<U, V>(U, result: inout V)

Calculates the square root of each element in a vector of single-precision values.

static func trunc<U>(U) -> [Double]

Returns the integer truncation of each element in a vector of double-precision values.

static func trunc<U>(U) -> [Float]

Returns the integer truncation of each element in a vector of single-precision values.

static func trunc<U, V>(U, result: inout V)

Calculates the integer truncation of each element in a vector of double-precision values.

static func trunc<U, V>(U, result: inout V)

Calculates the integer truncation of each element in a vector of single-precision values.

static func truncatingRemainder<U, V>(dividends: U, divisors: V) -> [Double]

Returns the remainder of the double-precision elements in dividends divided by the elements in divisors, using truncating division.

static func truncatingRemainder<U, V>(dividends: U, divisors: V) -> [Float]

Returns the remainder of the single-precision elements in dividends divided by the elements in divisors, using truncating division.

static func truncatingRemainder<T, U, V>(dividends: T, divisors: U, result: inout V)

Calculates the remainder of the double-precision elements in dividends divided by the elements in divisors, using truncating division.

static func truncatingRemainder<T, U, V>(dividends: T, divisors: U, result: inout V)

Calculates the remainder of the single-precision elements in dividends divided by the elements in divisors, using truncating division.

func vvceil(UnsafeMutablePointer<Double>, UnsafePointer<Double>, UnsafePointer<Int32>)

Calculates the ceiling of each element in an array of double-precision values.

func vvceilf(UnsafeMutablePointer<Float>, UnsafePointer<Float>, UnsafePointer<Int32>)

Calculates the ceiling of each element in an array of single-precision values.

func vvfloor(UnsafeMutablePointer<Double>, UnsafePointer<Double>, UnsafePointer<Int32>)

Calculates the floor of each element in an array of double-precision values.

func vvfloorf(UnsafeMutablePointer<Float>, UnsafePointer<Float>, UnsafePointer<Int32>)

Calculates the floor of each element in an array of single-precision values.

func vvcopysign(UnsafeMutablePointer<Double>, UnsafePointer<Double>, UnsafePointer<Double>, UnsafePointer<Int32>)

Copies an array, setting the sign of each element based on a second array of double-precision values.

func vvcopysignf(UnsafeMutablePointer<Float>, UnsafePointer<Float>, UnsafePointer<Float>, UnsafePointer<Int32>)

Copies an array, setting the sign of each element based on a second array of single-precision values.

func vvdiv(UnsafeMutablePointer<Double>, UnsafePointer<Double>, UnsafePointer<Double>, UnsafePointer<Int32>)

Divides each element in an array by the corresponding value in a second array of double-precision values.

func vvdivf(UnsafeMutablePointer<Float>, UnsafePointer<Float>, UnsafePointer<Float>, UnsafePointer<Int32>)

Divides each element in an array by the corresponding value in a second array of single-precision values.

func vvfabs(UnsafeMutablePointer<Double>, UnsafePointer<Double>, UnsafePointer<Int32>)

Calculates the absolute value for each element in an array of double-precision values.

func vvfabsf(UnsafeMutablePointer<Float>, UnsafePointer<Float>, UnsafePointer<Int32>)

Calculates the absolute value for each element in an array of single-precision values.

func vvfmod(UnsafeMutablePointer<Double>, UnsafePointer<Double>, UnsafePointer<Double>, UnsafePointer<Int32>)

Calculates the modulus after dividing each element in an array by the corresponding element in a second array of double-precision values.

func vvfmodf(UnsafeMutablePointer<Float>, UnsafePointer<Float>, UnsafePointer<Float>, UnsafePointer<Int32>)

Calculates the modulus after dividing each element in an array by the corresponding element in a second array of single-precision values.

func vvremainder(UnsafeMutablePointer<Double>, UnsafePointer<Double>, UnsafePointer<Double>, UnsafePointer<Int32>)

Calculates the remainder after dividing each element in an array by the corresponding element in a second array of double-precision values.

func vvremainderf(UnsafeMutablePointer<Float>, UnsafePointer<Float>, UnsafePointer<Float>, UnsafePointer<Int32>)

Calculates the remainder after dividing each element in an array by the corresponding element in a second array of single-precision values.

func vvint(UnsafeMutablePointer<Double>, UnsafePointer<Double>, UnsafePointer<Int32>)

Calculates the integer truncation for each element in an array of double-precision values.

func vvintf(UnsafeMutablePointer<Float>, UnsafePointer<Float>, UnsafePointer<Int32>)

Calculates the integer truncation for each element in an array of single-precision values.

func vvnint(UnsafeMutablePointer<Double>, UnsafePointer<Double>, UnsafePointer<Int32>)

Calculates the nearest integer for each element in an array of double-precision values.

func vvnintf(UnsafeMutablePointer<Float>, UnsafePointer<Float>, UnsafePointer<Int32>)

Calculates the nearest integer for each element in an array of single-precision values.

func vvrsqrt(UnsafeMutablePointer<Double>, UnsafePointer<Double>, UnsafePointer<Int32>)

Calculates the reciprocal square root of each element in an array of double-precision values.

func vvrsqrtf(UnsafeMutablePointer<Float>, UnsafePointer<Float>, UnsafePointer<Int32>)

Calculates the reciprocal square root of each element in an array of single-precision values.

func vvsqrt(UnsafeMutablePointer<Double>, UnsafePointer<Double>, UnsafePointer<Int32>)

Calculates the square root of each element in an array of double-precision values.

func vvsqrtf(UnsafeMutablePointer<Float>, UnsafePointer<Float>, UnsafePointer<Int32>)

Calculates the square root of each element in an array of single-precision values.

func vvrec(UnsafeMutablePointer<Double>, UnsafePointer<Double>, UnsafePointer<Int32>)

Calculates the reciprocal of each element in an array of double-precision values.

func vvrecf(UnsafeMutablePointer<Float>, UnsafePointer<Float>, UnsafePointer<Int32>)

Calculates the reciprocal of each element in an array of single-precision values.

func vvnextafterf(UnsafeMutablePointer<Float>, UnsafePointer<Float>, UnsafePointer<Float>, UnsafePointer<Int32>)

Calculates the next machine-representable value for each element in an array of single-precision values.