/// <summary> /// Ensures that temporary arrays are allocated in order to execute the Burg algorithm. /// </summary> /// <param name="xLength">Length of the vector to build the model.</param> /// <param name="coeffLength">Number of parameters of the model.</param> private void EnsureAllocation(int xLength, int coeffLength) { _numberOfCoefficients = coeffLength; if (null == _Ak || _Ak.Length < coeffLength + 1) { _Ak = new Complex[coeffLength + 1]; _AkWrapper = new ComplexVectorWrapper(_Ak, 1, _numberOfCoefficients); } if (_numberOfCoefficients != _AkWrapper.Length) { _AkWrapper = new ComplexVectorWrapper(_Ak, 1, _numberOfCoefficients); } if (null == _b || _b.Length < xLength) { _b = new Complex[xLength]; } if (null == _f || _f.Length < xLength) { _f = new Complex[xLength]; } }
/// <summary> /// Ensures that temporary arrays are allocated in order to execute the Burg algorithm. /// </summary> /// <param name="xLength">Length of the vector to build the model.</param> /// <param name="coeffLength">Number of parameters of the model.</param> private void EnsureAllocation(int xLength, int coeffLength) { _numberOfCoefficients = coeffLength; if (null == _Ak || _Ak.Length < coeffLength + 1) { _Ak = new Complex[coeffLength + 1]; _AkWrapper = new ComplexVectorWrapper(_Ak, 1, _numberOfCoefficients); } if (_numberOfCoefficients != _AkWrapper.Length) _AkWrapper = new ComplexVectorWrapper(_Ak, 1, _numberOfCoefficients); if (null == _b || _b.Length < xLength) _b = new Complex[xLength]; if (null == _f || _f.Length < xLength) _f = new Complex[xLength]; }