Back to C-ASPT Contents Page
Vector and matrix processing module
API Summary
Length calculation routines
DT32F vector operations
- DT32F fir32f(DT32F s, DT32F x[], const DT32F h[], DT32S xLen, DT32S hLen, DT32S *pos);
- DT32F firAdj32f(DT32F s, DT32F x[], const DT32F h[], DT32S xLen, DT32S hLen, DT32S *pos);
- DT32F dotProdCircBuf32f(DT32F x[], const DT32F h[], DT32S xLen, DT32S hLen, DT32S pos);
- DT32F dotProdLinBuf32f(const DT32F x[], const DT32F h[], DT32S N);
- DT32S sum32f(DT32F *src,DT32F *sum, DT32S N);
- DT32S sumAbs32f(DT32F *src,DT32F *sum, DT32S N);
- DT32S copy32f(const DT32F *src, DT32F *dst, DT32S N);
- DT32S set32f(DT32F g, DT32F *srcdst, DT32S N);
- DT32S reset32f(DT32F *srcdst, DT32S N);
- DT32S scaleAdd32f(DT32F scale, const DT32F *src1, const DT32F *src2, DT32F *dst, DT32S N);
- DT32S scaleAddIp32f(DT32F scale, const DT32F *src, DT32F *srcdst, DT32S N);
- DT32S smooth32f(DT32F a1, DT32F *src1, DT32F a2, DT32F *srcdst, DT32S N);
- DT32S add32f(const DT32F *src1, const DT32F *src2, DT32F *dst, DT32S N);
- DT32S addIp32f(const DT32F *src, DT32F *srcdst, DT32S N);
- DT32S sub32f(const DT32F *src1, const DT32F *src2, DT32F *dst, DT32S N);
- DT32S scaleIp32f(DT32F scale, DT32F *srcdst, DT32S N);
- DT32S divIp32f(const DT32F *src, DT32F d, DT32F *srcdst, DT32S N);
- DT32S div32f(const DT32F *src1, const DT32F *src2, DT32F d, DT32F *dst, DT32S N);
- DT32S insertSampleLinBuf32f(DT32F x, DT32F *buf, DT32S N);
Complex DT32FC vector operations
- DT32S powerSpectr32fc(const DT32FC *src, DT32F *dst, DT32S N);
- DT32S powerSpectrAdd32fc(const DT32FC *src, DT32F *srcdst, DT32S N);
- DT32S conjIp32fc(DT32FC *srcdst, DT32S N);
- DT32S conj32fc(DT32FC *src, DT32FC *dst, DT32S N);
- DT32S mpy32fc(const DT32FC *src1, const DT32FC *src2, DT32FC *dst, DT32S N);
- DT32S mpyIp32fc(const DT32FC *src, DT32FC *srcdst, DT32S N);
- DT32S mpyIp32f32fc(const DT32F *src, DT32FC *srcdst, DT32S N);
- DT32S mpyAdd32fc(const DT32FC *src1, const DT32FC *src2, DT32FC *srcdst, DT32S N);
- DT32S mpySub32fc(const DT32FC *src1, const DT32FC *src2, DT32FC *srcdst, DT32S N);
- DT32S divIp32f32fc(const DT32F *src, DT32F d, DT32FC *srcdst, DT32S N);
- DT32S subIp32fc(const DT32FC *src, DT32FC *srcdst, DT32S N);
- DT32S scaleIp32fc(DT32F scale, DT32FC *srcdst, DT32S N);
Half complex DT32FC vector operations
- DT32S powerSpectrR32fc(const DT32FC *src, DT32F *dst, DT32S N);
- DT32S powerSpectrAddR32fc(const DT32FC *src, DT32F *srcdst, DT32S N);
- DT32S conjIpR32fc(DT32FC *srcdst, DT32S N);
- DT32S conjR32fc(DT32FC *src, DT32FC *dst, DT32S N);
- DT32S mpyR32fc(const DT32FC *src1, const DT32FC *src2, DT32FC *dst, DT32S N);
- DT32S mpyIpR32fc(const DT32FC *src, DT32FC *srcdst, DT32S N);
- DT32S mpyIp32fR32fc(const DT32F *src, DT32FC *srcdst, DT32S N);
- DT32S mpyAddR32fc(const DT32FC *src1, const DT32FC *src2, DT32FC *srcdst, DT32S N);
- DT32S mpySubR32fc(const DT32FC *src1, const DT32FC *src2, DT32FC *srcdst, DT32S N);
- DT32S divIp32fR32fc(const DT32F *src, DT32F d, DT32FC *srcdst, DT32S N);
- DT32S subIpR32fc(const DT32FC *src, DT32FC *srcdst, DT32S N);
- DT32S scaleIpR32fc(DT32F scale, DT32FC *srcdst, DT32S N);
Description
Implements functions common to all algorithm in the package.
Copyright
Copyright (c) DSP ALGORITHMS 2003; all rights reserved.
<< Back to top
nextPow2
DT32S nextPow2(const DT64S N);
Calculates the smallest integer x such that 2^x > N- Input Parameters :
- Returns :
-
x : next power of 2 for which 2^x > N on success, otherwise an error code.
- Error Conditions
<< Back to top
rsum
DT32S rsum(DT32S x, DT32S y);
Calculates the sum from x to y n = sum(x:y)- Input Parameters :
- x : starting value
- y : end value
- Returns :
-
n : x + (x+1) + (x+2) + ... + y
- Output Parameters :
- Error Conditions
<< Back to top
insertSampleLinBuf32f
DT32S insertSampleLinBuf32f(DT32F x, DT32F *buf, DT32S N);
inserts a sample in a linear delay line.- Input Parameters :
- x : new input sample
- buf : delay line
- N : buffer length
- Returns :
- Output Parameters :
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
fir32f
DT32F fir32f(DT32F s, DT32F x[], const DT32F h[], DT32S xLen, DT32S hLen, DT32S *pos);
Calculates a FIR filter output and updates the delay line.- Input Parameters :
- s : new input sample
- x : delay line
- h : filter coefficients vector
- xLen : length of delay line
- hLen : length of coefficients vector
- pos : current circular buffer position.
- Returns :
- Output Parameters :
- x : updated delay line
- pos : updated circular buffer position
- Error Conditions
<< Back to top
firAdj32f
DT32F firAdj32f(DT32F s, DT32F x[], const DT32F h[], DT32S xLen, DT32S hLen, DT32S *pos);
Calculates a FIR filter output and updates the delay line. The filter coefficients are flipped before the calculation.- Input Parameters :
- s : new input sample
- x : delay line
- h : filter coefficients vector
- xLen : length of delay line
- hLen : length of coefficients vector
- pos : current circular buffer position.
- Returns :
- Output Parameters :
- x : updated delay line
- pos : updated circular buffer position
- Error Conditions
<< Back to top
dotProdCircBuf32f
DT32F dotProdCircBuf32f(DT32F x[], const DT32F h[], DT32S xLen, DT32S hLen, DT32S pos);
Calculates the dot product of the two vectors x[] and h[], where x[] is stored in a circular buffer with the newest sample pointed to by pos and h[] is stored in a linear buffer. The output equals to that returned by fir32f but the circular buffer is not updated.- Input Parameters :
- x : delay line
- h : filter coefficients vector
- xLen : length of delay line
- hLen : length of coefficients vector
- pos : current circular buffer position.
- Returns :
- Output Parameters :
- Error Conditions
<< Back to top
dotProdLinBuf32f
DT32F dotProdLinBuf32f(const DT32F x[], const DT32F h[], DT32S N);
Calculates the dot product of the two vectors x[] and h[], where both x[] and h[] are stored in linear buffers. The output equals. y += x[i] * h[i]; i=0,1,...,N-1- Input Parameters :
- x : delay line
- h : filter coefficients vector
- N : number of elements to process
- Returns :
- Output Parameters :
- Error Conditions
<< Back to top
reset32f
DT32S reset32f(DT32F *srcdst, DT32S N);
Resets N elements of the array srcdst to zero.- Input Parameters :
- srcdst : array to be reset
- N : number of elements to be reset
- Returns :
- Output Parameters :
- N elements starting at srcdst[0] are changed to zeros.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
set32f
DT32S set32f(DT32F g, DT32F *srcdst, DT32S N);
sets N elements of the array srcdst to a certain value g.- Input Parameters :
- srcdst : array to be initialized
- N : number of elements to be initialized
- Returns :
- Output Parameters :
- N elements starting at stcdst[0] are initialized to g.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
copy32f
DT32S copy32f(const DT32F *src, DT32F *dst, DT32S N);
copies N elements of the array src to the array dst.- Input Parameters :
- src : source array
- dst : destination array
- N : number of elements to be copied
- Returns :
- Output Parameters :
- N elements starting at dst[0] are initialized.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
sum32f
DT32S sum32f(DT32F *src,DT32F *sum, DT32S N);
calculates the sum of N elements of the array src and stores it in sum sum = src[0] + src[1] + ... + src[N-1]- Input Parameters :
- src : source array
- N : number of elements to be copied
- Returns :
- Output Parameters :
- sum : result of elements sum
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
sumAbs32f
DT32S sumAbs32f(DT32F *src,DT32F *sum, DT32S N);
calculates the sum of the absolute values of N elements of the array src and stores it in sum sum = abs(src[0]) + abs(src[1]) + ... + abs(src[N-1])- Input Parameters :
- src : source array
- N : number of elements to be copied
- Returns :
- Output Parameters :
- sum : result of elements sum
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
powerSpectrR32fc
DT32S powerSpectrR32fc(const DT32FC *src, DT32F *dst, DT32S N);
stores the power spectrum of the complex array src of length N into the real array dst of length N+1 elements. The source array is the FFT of a real vector and stored in the compact form.- Input Parameters :
- src : source array of N complex data elements
- dst : destination array to store the power spectrum of src
- N : number of elements to process
- Returns :
- Output Parameters :
- dst contains the power spectrum of src.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
powerSpectr32fc
DT32S powerSpectr32fc(const DT32FC *src, DT32F *dst, DT32S N);
stores the power spectrum of the complex array src of length N into the real array dst of length N elements.- Input Parameters :
- src : source array of N complex data elements
- dst : destination array to store the power spectrum of src
- N : number of elements to process
- Returns :
- Output Parameters :
- dst contains the power spectrum of src.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
powerSpectrAddR32fc
DT32S powerSpectrAddR32fc(const DT32FC *src, DT32F *srcdst, DT32S N);
Calculates the power spectrum of the complex array src of length N and adds it to the contents of the real array srcdst of length N+1. The src array is the FFT of a real vector stored in the compact form.- Input Parameters :
- src : source array of N complex data elements
- srcdst : destination array to store the power spectrum of src
- N : number of elements to process
- Returns :
- Output Parameters :
- srcdst contains the accumulated power spectrum of src.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
powerSpectrAdd32fc
DT32S powerSpectrAdd32fc(const DT32FC *src, DT32F *srcdst, DT32S N);
Calculates the power spectrum of the complex array src of length N and adds it to the contents of the real array srcdst of length N. - Input Parameters :
- src : source array of N complex data elements
- srcdst : destination array to store the power spectrum of src
- N : number of elements to process
- Returns :
- Output Parameters :
- srcdst contains the accumulated power spectrum of src.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
conjIpR32fc
DT32S conjIpR32fc(DT32FC *srcdst, DT32S N);
replaces the complex array srcdst by its complex conjugate. The input array is the FFT of a real vector stored in the compact form.- Input Parameters :
- srcdst : source/destination array of N complex data elements
- N : number of elements to process
- Returns :
- Output Parameters :
- srcdst contains the complex conjugate of its contents before the call.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
conjIp32fc
DT32S conjIp32fc(DT32FC *srcdst, DT32S N);
replaces the complex array srcdst by its complex conjugate. - Input Parameters :
- srcdst : source/destination array of N complex data elements
- N : number of elements to process
- Returns :
- Output Parameters :
- srcdst contains the complex conjugate of its contents before the call.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
conjR32fc
DT32S conjR32fc(DT32FC *src, DT32FC *dst, DT32S N);
Calculates the complex conjugate of src and stores the result in dst. The input array is the FFT of a real vector stored in the compact form.- Input Parameters :
- src : source array of N complex data elements
- dst : destination array
- N : number of elements to process
- Returns :
- Output Parameters :
- dst contains the complex conjugate of the contents of src.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
conj32fc
DT32S conj32fc(DT32FC *src, DT32FC *dst, DT32S N);
Calculates the complex conjugate of src and stores the result in dst. The input array is the FFT of a real vector stored in the compact form.- Input Parameters :
- src : source array of N complex data elements
- dst : destination array
- N : number of elements to process
- Returns :
- Output Parameters :
- dst contains the complex conjugate of the contents of src.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
mpyR32fc
DT32S mpyR32fc(const DT32FC *src1, const DT32FC *src2, DT32FC *dst, DT32S N);
element-wise multiplies the complex arrays src1 and src2 and stores the result into the complex array dst. The input arrays are the FFT of real vectors stored in the compact form. The result is also stored in the compact format. dst[i] = src1[i] * src2[i]; i=0,1,..,N-1.- Input Parameters :
- src1 : first source array of N complex data elements
- src2 : second source array of N complex data elements
- dst : destination array for the complex multiplication result
- N : number of elements to process
- Returns :
- Output Parameters :
- dst contains the complex multiplication result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
mpy32fc
DT32S mpy32fc(const DT32FC *src1, const DT32FC *src2, DT32FC *dst, DT32S N);
element-wise multiplies the complex arrays src1 and src2 and stores the result into the complex array dst. dst[i] = src1[i] * src2[i]; i=0,1,..,N-1.- Input Parameters :
- src1 : first source array of N complex data elements
- src2 : second source array of N complex data elements
- dst : destination array for the complex multiplication result
- N : number of elements to process
- Returns :
- Output Parameters :
- dst contains the complex multiplication result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
mpyAddR32fc
DT32S mpyAddR32fc(const DT32FC *src1, const DT32FC *src2, DT32FC *srcdst, DT32S N);
element-wise multiplies the complex arrays src1 and src2, adds the result to the contents of the complex array srcdst. The input arrays are the FFT of real vectors stored in the compact form. The result is also stored in the compact format. srcdst[i] += src1[i] * src2[i]; i=0,1,..,N-1.- Input Parameters :
- src1 : first source array of N complex data elements
- src2 : second source array of N complex data elements
- srcdst : source/destination array for the complex multiplication result
- N : number of elements to process
- Returns :
- Output Parameters :
- dst contains the complex multiplication result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
mpyAdd32fc
DT32S mpyAdd32fc(const DT32FC *src1, const DT32FC *src2, DT32FC *srcdst, DT32S N);
element-wise multiplies the complex arrays src1 and src2, adds the result to the contents of the complex array srcdst. The input arrays are the FFT of real vectors stored in the compact form. The result is also stored in the compact format. srcdst[i] += src1[i] * src2[i]; i=0,1,..,N-1.- Input Parameters :
- src1 : first source array of N complex data elements
- src2 : second source array of N complex data elements
- srcdst : source/destination array for the complex multiplication result
- N : number of elements to process
- Returns :
- Output Parameters :
- dst contains the complex multiplication result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
mpySubR32fc
DT32S mpySubR32fc(const DT32FC *src1, const DT32FC *src2, DT32FC *srcdst, DT32S N);
element-wise multiplies the complex arrays src1 and src2, and subtracts the result from the contents of the complex array srcdst. The input arrays are the FFT of real vectors stored in the compact form. The result is also stored in the compact format. srcdst[i] -= src1[i] * src2[i]; i=0,1,..,N-1.- Input Parameters :
- src1 : first source array of N complex data elements
- src2 : second source array of N complex data elements
- srcdst : source/destination array for the complex multiplication result
- N : number of elements to process
- Returns :
- Output Parameters :
- dst contains the complex multiplication result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
mpySub32fc
DT32S mpySub32fc(const DT32FC *src1, const DT32FC *src2, DT32FC *srcdst, DT32S N);
element-wise multiplies the complex arrays src1 and src2, and subtracts the result from the contents of the complex array srcdst. srcdst[i] -= src1[i] * src2[i]; i=0,1,..,N-1.- Input Parameters :
- src1 : first source array of N complex data elements
- src2 : second source array of N complex data elements
- srcdst : source/destination array for the complex multiplication result
- N : number of elements to process
- Returns :
- Output Parameters :
- dst contains the complex multiplication result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
mpyIpR32fc
DT32S mpyIpR32fc(const DT32FC *src, DT32FC *srcdst, DT32S N);
element-wise multiplies the complex arrays src and srcdst and stores the result into the complex array srcdst. The input arrays are the FFT of real vectors stored in the compact form. The result is also stored in the compact format. srcdst[i] = srcdst[i] * src[i]; i=0,1,..,N-1.- Input Parameters :
- src : first source array of N complex data elements
- srcdst : second source array of N complex data elements, and
destination array for the complex multiplication result
- N : number of complex elements to process
- Returns :
- Output Parameters :
- srcdst contains the complex multiplication result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
mpyIp32fc
DT32S mpyIp32fc(const DT32FC *src, DT32FC *srcdst, DT32S N);
element-wise multiplies the complex arrays src and srcdst and stores the result into the complex array srcdst. srcdst[i] = srcdst[i] * src[i]; i=0,1,..,N-1.- Input Parameters :
- src : first source array of N complex data elements
- srcdst : second source array of N complex data elements, and
destination array for the complex multiplication result
- N : number of complex elements to process
- Returns :
- Output Parameters :
- srcdst contains the complex multiplication result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
mpyIp32fR32fc
DT32S mpyIp32fR32fc(const DT32F *src, DT32FC *srcdst, DT32S N);
element-wise multiplies the DT32S array src and complex srcdst and stores the complex result into the array srcdst. The srcdst array is the FFT of a real vector stored in the compact form. The result is also stored in the compact format. srcdst[i] = srcdst[i] * src[i]; i=0,1,..,N-1.- Input Parameters :
- src : first source array of N DT32S data elements
- srcdst : second source array of N complex data elements, and
destination array for the complex multiplication result
- N : number of elements to process
- Returns :
- Output Parameters :
- srcdst contains the complex multiplication result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
mpyIp32f32fc
DT32S mpyIp32f32fc(const DT32F *src, DT32FC *srcdst, DT32S N);
element-wise multiplies the DT32S array src and complex srcdst and stores the complex result into the array srcdst. srcdst[i] = srcdst[i] * src[i]; i=0,1,..,N-1.- Input Parameters :
- src : first source array of N DT32S data elements
- srcdst : second source array of N complex data elements, and
destination array for the complex multiplication result
- N : number of elements to process
- Returns :
- Output Parameters :
- srcdst contains the complex multiplication result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
subIpR32fc
DT32S subIpR32fc(const DT32FC *src, DT32FC *srcdst, DT32S N);
element-wise subtracts the complex array src from the complex array srcdst and stores the complex result into the array srcdst. The input arrays are the FFT of real vectors stored in the compact form. The result is also stored in the compact format. srcdst[i] = srcdst[i] - src[i]; i=0,1,..,N-1.- Input Parameters :
- src : source array of N complex data elements
- srcdst : second source array of N complex data elements, and
destination array for the complex subtraction result
- N : number of elements to process
- Returns :
- Output Parameters :
- srcdst contains the complex subtraction result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
subIp32fc
DT32S subIp32fc(const DT32FC *src, DT32FC *srcdst, DT32S N);
element-wise subtracts the complex array src from the complex array srcdst and stores the complex result into the array srcdst. srcdst[i] = srcdst[i] - src[i]; i=0,1,..,N-1.- Input Parameters :
- src : source array of N complex data elements
- srcdst : second source array of N complex data elements, and
destination array for the complex subtraction result
- N : number of elements to process
- Returns :
- Output Parameters :
- srcdst contains the complex subtraction result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
scaleIp32f
DT32S scaleIp32f(DT32F scale, DT32F *srcdst, DT32S N);
scales the DT32F elements of the array srcdst in place by the factor scale. srcdst[i] *= scale; i=0,1,..,N-1.- Input Parameters :
- scale : scale factor
- srcdst : source/destination array of N DT32F data elements
- N : number of elements to process
- Returns :
- Output Parameters :
- srcdst contains the scaled elements.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
scaleIpR32fc
DT32S scaleIpR32fc(DT32F scale, DT32FC *srcdst, DT32S N);
scales the DT32FC elements of the complex array srcdst in place by the factor scale. The srcdst array is the FFT of a real vector stored in the compact form. The result is also stored in the compact format. . srcdst[i] *= scale; i=0,1,..,N-1.- Input Parameters :
- scale : scale factor (DT32F)
- srcdst : source/destination array of N DT32FC data elements
- N : number of elements to process
- Returns :
- Output Parameters :
- srcdst contains the scaled elements.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
scaleIp32fc
DT32S scaleIp32fc(DT32F scale, DT32FC *srcdst, DT32S N);
scales the DT32FC elements of the complex array srcdst in place by the factor scale. . srcdst[i] *= scale; i=0,1,..,N-1.- Input Parameters :
- scale : scale factor (DT32F)
- srcdst : source/destination array of N DT32FC data elements
- N : number of elements to process
- Returns :
- Output Parameters :
- srcdst contains the scaled elements.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
divIp32fR32fc
DT32S divIp32fR32fc(const DT32F *src, DT32F d, DT32FC *srcdst, DT32S N);
Divides each element of the complex array srcdst[] by the corresponding element of the DT32F array src[]. The srcdst array is the FFT of a real vector stored in the compact form. The result is also stored in the compact format. srcdst[i] = srcdst[i] / (src[i]+d); i=0,1,..,N-1.- Input Parameters :
- src : first source array of N DT32S data elements
- d : deregularization factor to avoid dividing by zero
- srcdst : second source array of N complex DT32FC data elements, and
destination array for the division result
- N : number of elements to process
- Returns :
- Output Parameters :
- srcdst contains the division result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
divIp32f32fc
DT32S divIp32f32fc(const DT32F *src, DT32F d, DT32FC *srcdst, DT32S N);
Divides each element of the complex array srcdst[] by the corresponding element of the DT32F array src[]. srcdst[i] = srcdst[i] / (src[i]+d); i=0,1,..,N-1.- Input Parameters :
- src : first source array of N DT32S data elements
- d : deregularization factor to avoid dividing by zero
- srcdst : second source array of N complex DT32FC data elements, and
destination array for the division result
- N : number of elements to process
- Returns :
- Output Parameters :
- srcdst contains the division result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
add32f
DT32S add32f(const DT32F *src1, const DT32F *src2, DT32F *dst, DT32S N);
element-wise adds the arrays src1 and src2 and stores the result in the array dst. dst[i] = src1[i] + src2[i]; i=0,1,..,N-1.- Input Parameters :
- src1 : first source array of N data elements
- src1 : second source array of N data elements
- dst : destination array for the addition result
- N : number of elements to process
- Returns :
- Output Parameters :
- dst contains the element-wise sum result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
addIp32f
DT32S addIp32f(const DT32F *src, DT32F *srcdst, DT32S N);
element-wise adds the arrays src and srcdst and stores the result in srcdst. srcdst[i] += src; i=0,1,..,N-1.- Input Parameters :
- src : first source array of N data elements
- srcdst : second source array of N data elements and destination array
- N : number of elements to process
- Returns :
- Output Parameters :
- dst contains the element-wise sum result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
sub32f
DT32S sub32f(const DT32F *src1, const DT32F *src2, DT32F *dst, DT32S N);
element-wise subtracts the arrays src1 from src2 and stores the result in the array dst. dst[i] = src2[i] - src1[i]; i=0,1,..,N-1.- Input Parameters :
- src1 : first source array of N data elements
- src1 : second source array of N data elements
- dst : destination array for the addition result
- N : number of elements to process
- Returns :
- Output Parameters :
- dst contains the element-wise subtraction result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
scaleAdd32f
DT32S scaleAdd32f(DT32F scale, const DT32F *src1, const DT32F *src2, DT32F *dst, DT32S N);
scales src1 elements by the scale value, element-wise adds the scaling result to src2 and stores the result in the array dst. dst[i] = scale * src1[i] + src2[i]; i=0,1,..,N-1.- Input Parameters :
- scale : scale factor;
- src1 : first source array of N data elements
- src1 : second source array of N data elements
- dst : destination array for the addition result
- N : number of elements to process
- Returns :
- Output Parameters :
- dst contains the element-wise sum result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
scaleAddIp32f
DT32S scaleAddIp32f(DT32F scale, const DT32F *src, DT32F *srcdst, DT32S N);
scales src1 elements by the scale value, element-wise adds the scaling result to srcdst and stores the result in the array srcdst. srcdst[i] += scale * src[i]; i=0,1,..,N-1.- Input Parameters :
- scale : scale factor;
- src : first source array of N data elements
- srcdst : second source array of N data elements and destination array
- N : number of elements to process
- Returns :
- Output Parameters :
- srcdst contains the element-wise sum result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
smooth32f
DT32S smooth32f(DT32F a1, DT32F *src1, DT32F a2, DT32F *srcdst, DT32S N);
scales src1 elements by a1, srcdst elements by a2, element-wise adds the scaled vectors, and stores the result in the array srcdst. srcdst[i] = a1 * src1[i] + a2 * srcdst[i]; i=0,1,..,N-1.- Input Parameters :
- a1 : scale factor for first input vector src1
- src1 : first source array of N data elements
- a2 : scale factor for second input vector srcdst
- srcdst : second source array and destination array of N data elements
- N : number of elements to process
- Returns :
- Output Parameters :
- srcdst contains the filtering result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
divIp32f
DT32S divIp32f(const DT32F *src, DT32F d, DT32F *srcdst, DT32S N);
Divides each element of the DT32F array srcdst[] by the corresponding element of the DT32F array src[]. srcdst[i] = srcdst[i] / (src[i]+d); i=0,1,..,N-1.- Input Parameters :
- src : first source array of N DT32F data elements
- d : deregularization factor to avoid dividing by zero
- srcdst : second source array of N DT32F data elements, and
destination array for the division result
- N : number of elements to process
- Returns :
- Output Parameters :
- srcdst contains the division result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR
<< Back to top
div32f
DT32S div32f(const DT32F *src1, const DT32F *src2, DT32F d, DT32F *dst, DT32S N);
Divides each element of the DT32F array src1[] by the corresponding element of the DT32F array src2[] and stores the result in dst[]. dst[i] = src1[i] / (src2[i] + d); i=0,1,..,N-1.- Input Parameters :
- src1 : first source array of N DT32F data elements
- src2 : second source array of N DT32F data elements
- d : deregularization factor to avoid dividing by zero
- dst : destination array for the division result
- N : number of elements to process
- Returns :
- Output Parameters :
- srcdst contains the division result.
- Error Conditions
- ASPT_NO_ERR
- ASPT_NULL_PTR_ERR