# Exec

Computes convolution or correlation for multidimensional case.

## Syntax

Fortran:

status = vslsconvexec(task, x, xstride, y, ystride, z, zstride)

status = vsldconvexec(task, x, xstride, y, ystride, z, zstride)

status = vslscorrexec(task, x, xstride, y, ystride, z, zstride)

status = vsldcorrexec(task, x, xstride, y, ystride, z, zstride)

C:

status = vslsConvExec(task, x, xstride, y, ystride, z, zstride);

status = vsldConvExec(task, x, xstride, y, ystride, z, zstride);

status = vslsCorrExec(task, x, xstride, y, ystride, z, zstride);

status = vsldCorrExec(task, x, xstride, y, ystride, z, zstride);

## Description

Each of the Exec routines computes convolution or correlation of the data provided by the arrays x and y and then stores the results in the array z. Parameters of the operation are read from the task descriptor created previously by a corresponding NewTask constructor and pointed to by task. If task is NULL, no operation is done.

The stride parameters xstride, ystride, and zstride specify the physical location of the input and output data in the arrays x, y, and z, respectively. In a one-dimensional case, stride is an interval between locations of consecutive elements of the array. For example, if the value of the parameter zstride is s, then only every sth element of the array z will be used to store the output data. The stride value must be positive or negative but not zero.

## Input Parameters

Name | Type | Description
--- | --- | ---
task | FORTRAN: TYPE(VSL_CONV_TASK) for vslsconvexec and vsldconvexec TYPE(VSL_CORR_TASK) for vslscorrexec and vsldcorrexec C: VSLConvTaskPtr for vslsConvExec and vsldConvExec VSLCorrTaskPtr for vslsCorrExec and vsldCorrExec | Pointer to the task descriptor.
x , y | FORTRAN: REAL(KIND=4), DIMENSION(*) for vslsconvexec and vslscorrexec REAL(KIND=8), DIMENSION(*) for vsldconvexec and vsldcorrexec C: float[] for vslsConvExec and vslsCorrExec double[] for vsldConvExec and vsldCorrExec | Pointers to arrays containing input data. See Data Allocation for more information.
xstride, ystride, zstride | FORTRAN: INTEGER, DIMENSION(*) C: int[] | Strides for input and output data. For more information, see stride parameters.

## Output Parameters

Name | Type | Description
--- | --- | ---
z | FORTRAN: REAL(KIND=4), DIMENSION(*) for vslsconvexec and vslscorrexec REAL(KIND=8), DIMENSION(*) for vsldconvexec and vsldcorrexec C: float[] for vslsConvExec and vslsCorrExec double[] for vsldConvExec and vsldCorrExec | Pointer to the array that stores output data. See Data Allocation for more information.
status | FORTRAN: INTEGER C: int | Set to VSL_STATUS_OK if the task is executed successfully or set to non-zero error code otherwise.

Parent topic: Task Execution Routines