Click or drag to resize

DoubleComplex1DConvolution Class

DoubleComplex1DConvolution represents a 1D convolution, with a specified kernel and data length.
Inheritance Hierarchy
SystemObject
  CenterSpace.NMath.CoreConvolutionBase
    CenterSpace.NMath.CoreDoubleComplex1DConvolution

Namespace: CenterSpace.NMath.Core
Assembly: NMath (in NMath.dll) Version: 7.4
Syntax
[SerializableAttribute]
public class DoubleComplex1DConvolution : ConvolutionBase, 
	ICloneable

The DoubleComplex1DConvolution type exposes the following members.

Constructors
 NameDescription
Public methodDoubleComplex1DConvolution(DoubleComplex, Int32) Constructs a convolution instance and defines the convolution kernel, and input signal data length.
Public methodDoubleComplex1DConvolution(DoubleComplexVector, Int32) Constructs a convolution instance and defines the convolution kernel, and input signal data length.
Public methodDoubleComplex1DConvolution(DoubleComplex, Int32, Int32, Int32) Constructs a convolution instance and defines the convolution kernel with a given offset and stride.
Top
Properties
 NameDescription
Public propertyDataLength Gets the length of the convolution data.
(Inherited from ConvolutionBase)
Public propertyKernelLength Gets the length of the convolution kernel.
(Inherited from ConvolutionBase)
Public propertyKernelShape Gets the shape of the convolution kernel.
(Inherited from ConvolutionBase)
Public propertyLength Gets the length of the convolution.
(Inherited from ConvolutionBase)
Top
Methods
 NameDescription
Public methodClone Creates a deep copy of this convolution instance.
Public methodConvolve(DoubleComplex) Computes the convolution between the stored convolution kernel, and the vector data.
Public methodConvolve(DoubleComplexVector) Computes the convolution between the stored convolution kernel, and the vector data.
Public methodConvolve(DoubleComplex, DoubleComplex) Computes the convolution between the stored convolution kernel, and the vector data.
Public methodConvolve(DoubleComplexVector, DoubleComplexVector) Computes the convolution between the stored convolution kernel, and the vector data.
Protected methodFinalize Provides non-deterministic destruction of underlying unmanaged resources.
(Inherited from ConvolutionBase)
Public methodTrimConvolution(DoubleComplexVector, ConvolutionBaseWindowing) Creates a clipped view into the convolution. This does not create a copy of the input convolution.
Protected methodTrimConvolutionT(T, ConvolutionBaseWindowing) Creates a windowed view into the convolution. This does not create a copy of the input convolution.
(Inherited from ConvolutionBase)
Top
Fields
 NameDescription
Protected fieldkerneloffset_ Convolution kernel offset.
(Inherited from ConvolutionBase)
Protected fieldkernelstride_ Convolution kernel stride.
(Inherited from ConvolutionBase)
Protected fieldmode_ Mode is either automatic, fft, or direct sum.
(Inherited from ConvolutionBase)
Top
Remarks
The convolution length = length_of_data + length_of_kernel - 1. Mathematically, the kernel and the input data can be interchanged without changing the convolution result. However, in practice, often the kernel is much shorter than the data and is used over many convolution operations against different data sets. This class is designed to be used in that fashion and the higest performance will be acheived if the kernel is fixed over a series of convolution operations.
Example
C#
// 1D Convolution example
   DoubleComplexVector kernel = new DoubleComplexVector("(1,1) (2,2) (2,2) (1,1)");
   DoubleComplexVector data = new DoubleComplexVector(1, 2, 3, 4, 5, 6, 7, 8, 9);

   DoubleComplex1DConvolution cv = new DoubleComplex1DConvolution(kernel, data.Length);

   DoubleComplexVector z = cv.Convolve(data);

// Now z contains the convolution result, z = kernel*data, of length 13.
See Also