---
title: vDSP_sve_svesqD
framework: accelerate
role: symbol
role_heading: Function
path: accelerate/vdsp_sve_svesqd
---

# vDSP_sve_svesqD

Calculates the sum of values and the sum of squares in a double-precision vector.

## Declaration

```occ
extern void vDSP_sve_svesqD(const double *__A, vDSP_Stride __IA, double *__Sum, double *__SumOfSquares, vDSP_Length __N);
```

## Parameters

- `__A`: Double-precision input vector.
- `__IA`: Stride for the input vector.
- `__Sum`: Double-precision sum (scalar) of the elements of A.
- `__SumOfSquares`: Double-precision sum (scalar) of the squares of the elements of A.
- `__N`: Number of elements in A.

## Discussion

Discussion This function calculates the sum of values and the sum of squares of the first N elements of A and writes the result to Sum and SumOfSquares respectively:

The operation is: Sum          = sum(A[n],      0 <= n < N); SumOfSquares = sum(A[n] ** 2, 0 <= n < N);

## See Also

### Vector Summation

- [vDSP_sve](accelerate/vdsp_sve.md)
- [vDSP_sveD](accelerate/vdsp_sved.md)
- [vDSP_svemg](accelerate/vdsp_svemg.md)
- [vDSP_svemgD](accelerate/vdsp_svemgd.md)
- [vDSP_svesq](accelerate/vdsp_svesq.md)
- [vDSP_svesqD](accelerate/vdsp_svesqd.md)
- [vDSP_sve_svesq](accelerate/vdsp_sve_svesq.md)
- [vDSP_svs](accelerate/vdsp_svs.md)
- [vDSP_svsD](accelerate/vdsp_svsd.md)
