Table Of Contents

Integral x(t) (G Dataflow)

Version:
    Last Modified: January 9, 2017

    Performs the discrete integration of the sampled signal.

    connector_pane_image
    datatype_icon

    x(t)

    Sampled signal from time 0 to n-1, where n is the number of elements in the sampled signal.

    datatype_icon

    integration method

    Method to use to perform the numeric integration.

    Name Value Description
    Trapezoidal Rule 0 Uses the trapezoidal rule.
    Simpson's Rule 1 Uses the Simpson's rule.
    Simpson's 3/8 Rule 2 Uses the Simpson's 3/8 rule.
    Bode Rule 3 Uses the Bode rule.

    Default: Simpson's Rule

    datatype_icon

    initial condition

    Initial condition of the sampled signal in the integration calculation.

    This node uses the first element of the initial condition to calculate the integration if the integration method is the Trapezoidal Rule or Simpson's Rule. This node uses the first two elements in the initial condition to calculate the integration if the integration method is the Simpson's 3/8 Rule or Bode Rule.

    datatype_icon

    final condition

    Final condition of the sampled signal in the integration calculation.

    This node ignores the final condition if the integration method is Trapezoidal Rule. This node uses the first element in the final condition to calculate the integration if the integration method is the Simpson's Rule or Simpson's 3/8 Rule. This node uses the first two elements to calculate the integration if the integration method is Bode Rule.

    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

    dt

    Sampling interval.

    Default: 1

    datatype_icon

    integral x(t)

    Discrete integration of the sampled signal.

    datatype_icon

    error out

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

    Algorithm for Calculating the Integral

    Integral x(t) calculates a definite integral. The value of the output array at any value x is the area under the curve of the input array between 0 and x.

    The integral F(t) of a function f(t) is defined by the following equation.

    F ( t ) = f ( t ) dt

    Let y represent the sampled output sequence integral x(t).

    If integration method is Trapezoidal Rule, this node obtains the elements of y using the following equation:

    y i = d t 2 j = 0 i ( x j 1 + x j )

    for i = 0, 1, 2, ..., n - 1,

    where n is the number of samples in x(t) and x-1 is the first element in initial condition.

    If integration method is Simpson's Rule, this obtains the elements of y using the following equation:

    y i = d t 6 j = 0 i ( x j 1 + 4 x j + x j + 1 )

    for i = 0, 1, 2, ..., n - 1

    where

    • n is the number of samples in x(t)
    • x-1 is the first element in initial condition
    • xn is the first element in final condition

    If integration method is Simpson's 3/8 Rule, this node obtains the elements of y using the following equation:

    y i = d t 8 j = 0 i ( x j 2 + 3 x j 1 + 3 x j + x j + 1 )

    for i = 0, 1, 2, ..., n - 1

    where

    • n is the number of samples in x(t)
    • x-2 and x-1 are the first and second elements in initial condition
    • xn is the first element in final condition

    If integration method is Bode Rule, this node obtains the elements of y using the following equation:

    y i = d t 90 j = 0 i ( 7 x j 2 + 32 x j 1 + 12 x j + 32 x j + 1 + 7 x j + 2 )

    for i = 0, 1, 2, ..., n - 1,

    where

    • n is the number of samples in x(t)
    • x-2 and x-1 are the first and second elements in initial condition
    • xn and xn+1 are the first and second elements in final condition

    The initial condition and final condition minimize the overall error by increasing the accuracy at the boundaries, especially when the number of samples is small. Determining boundary conditions before the fact enhances accuracy.

    Where This Node Can Run:

    Desktop OS: Windows

    FPGA: Not supported


    Recently Viewed Topics