Table Of Contents

Signal Correlation (2D Cross Correlation) (G Dataflow)

Version:
    Last Modified: January 9, 2017

    Computes the two-dimensional cross correlation of two sequences.

    connector_pane_image
    datatype_icon

    X

    The first input sequence.

    This input can be a 2D array of double-precision, floating-point numbers or a 2D array of complex double-precision, floating-point numbers.

    datatype_icon

    Y

    The second input sequence.

    This input can be a 2D array of double-precision, floating-point numbers or a 2D array of complex double-precision, floating-point numbers.

    datatype_icon

    algorithm

    The correlation method to use.

    If x and y are small, the direct method typically is faster. If x and y are large, the frequency domain method typically is faster. Additionally, slight numerical differences can exist between the two methods.

    Name Description
    direct

    Computes the cross correlation using the direct method of linear correlation.

    frequency domain

    Computes the cross correlation using an FFT-based technique.

    Default: frequency domain

    datatype_icon

    error in

    Error conditions that occur before this node runs. The node responds to this input according to standard error behavior.

    Default: No error

    datatype_icon

    RXY

    The cross correlation of the two input sequences.

    datatype_icon

    error out

    Error information. The node produces this output according to standard error behavior.

    Algorithm for Calculating the 2D Cross Correlation

    This node computes two-dimensional cross correlation as follows:

    h ( i , j ) = m = 0 M 1 1 n = 0 N 1 1 x * ( m , n ) y ( m i , n j )

    for i = -(M1-1), ..., -1, 0, 1, ... , (M2-1) and j = -(N1-1), ..., -1, 0, 1, ... , (N2-1)

    where

    • M1 is the number of rows of matrix X
    • N1 is the number of columns of matrix X
    • M2 is the number of rows of matrix Y
    • N2 is the number of columns of matrix Y

    The indexed elements outside the ranges of X and Y are equal to zero, as shown in the following relationships:

    x ( m , n ) = 0 , m < 0 or m M 1 or n < 0 or n N 1

    and

    y ( m , n ) = 0 , m < 0 or m M 2 or n < 0 or n N 2

    The elements of the output matrix RXY are related to the elements in h as follows:

    R x y ( i , j ) = h ( i ( M 1 1 ) , j ( N 1 1 ) ) for i = 0 , 1 , 2 , ... , M 1 + M 2 2 and j = 0 , 1 , 2 , ... , N 1 + N 2 2

    Where This Node Can Run:

    Desktop OS: Windows

    FPGA: Not supported


    Recently Viewed Topics