vDSP_vsaddD
Calculates the double-precision element-wise sum of a vector and a scalar value, using the specified stride.
Declaration
extern void vDSP_vsaddD(const double *__A, vDSP_Stride __IA, const double *__B, double *__C, vDSP_Stride __IC, vDSP_Length __N);Parameters
- __A:
The input vector,
A. - __IA:
The distance between the elements in the input vector.
- __B:
The input scalar,
B. - __C:
The output vector,
C. - __IC:
The distance between the elements in the output vector.
- __N:
The number of elements that the function processes.
Discussion
This function calculates the element-wise sum of vector A and scalar value B, and writes the result to vector C, as follows:
for (n = 0; n < N; ++n)
C[n] = A[n] + B;[Image]
The following code shows an example of using this function: