Caculate the power of a serial of signal sequences which is stored in the input array(vSig).
Each signal sequence has the same width. Actually they are the result of FFT transform
of a window of source signal as Hermitian-Form.
int fft_get_power_hermitian( int iSeqSize, int iNumSeq, double * vSig, double * vResult )
Returns 0 for success or error codes for failure.
//Assume in the current worksheet, the first column is the result of FFT transform of a
//window of source signal as Hermitian-Form. The signal data contains 20 value, every 5
//represents a fft result of a sequence applied window. And there are 4 sequences in this
//vector. At last the column B will show the result.
Worksheet wks = Project.ActiveLayer();
Dataset dsSig(wks, 0);
Dataset dsResult(wks, 1);
vector vecSig, vecResult;
vecSig = dsSig;
int nPadWinSize = 5; // this is the length of sub-sequence of signal
int nSteps = 4; // number of sub-sequence.
int ret = fft_get_power_hermitian(nPadWinSize, nSteps, vecSig, vecResult);
if (ret !=0 )
out_str("return error, fail call");
dsResult = vecResult;