주요 콘텐츠

Integrate and Dump

Integrate discrete-time signal with periodic resets

  • Integrate and Dump block

Libraries:
Communications Toolbox / Comm Filters

Description

The Integrate and Dump block creates a cumulative sum of the discrete-time input signal, while resetting the sum to zero according to a fixed schedule. When the simulation begins, the block discards the number of samples specified in the Offset (number of samples) parameter. After the initial offset, the block sums the input signal along columns and resets the sum to zero every N input samples, where N is the Integration period (number of samples) parameter value. The reset occurs after the block produces its output at that time step. For more information, see More About.

Receiver models often use the integrate-and-dump operation to receive simple square-pulse transmissions. Fiber optics and spread-spectrum communications systems also use the integrate-and-dump operation.

Examples

expand all

Apply the integrate-and-dump filter with an integration period of 20 samples to noisy random binary data.

The cm_int_dump_filtering model upsamples BPSK modulated random binary data, adds noise to the data, and then applies integrate-and-dump filtering. A timescope plots the real component of samples for a frame of the transmitted random integer data (tx) and the received data after integrate and dump filtering (rx).

Ports

Input

expand all

Input signal, specified as a scalar, column vector, or matrix. Nonscalar input signals must consist of one or more columns with (k×N) rows. The block treats each column as an independent channel, performing integration along each column. k is a positive integer and N is the value of Integration period (number of samples).

This port is unnamed on the block.

Data Types: single | double | int8 | int16 | int32 | uint8 | uint16 | uint32 | Boolean

Output

expand all

Output signal, returned as a column vector or matrix. The number of rows in the output signal varies based on the value assigned to Output intermediate values parameter.

This port is unnamed on the block.

Parameters

expand all

To edit block parameters interactively, use the Property Inspector. From the Simulink® Toolstrip, on the Simulation tab, in the Prepare gallery, select Property Inspector.

Main

Number of input samples between resets, specified as an integer in the range [2, ∞).

Number of input samples to discard from each column of input data at the beginning of the simulation, specified as a nonnegative integer scalar or vector. When you set this parameter to a nonzero value, the block outputs zeros in place of the discarded initial input samples.

  • When you specify this parameter as a vector of length L, each element of the vector represents the number of samples to discard from the corresponding channel (column) of the input data matrix. The length of the vector L must match the number of columns in the input data matrix.

  • When you specify this property as a scalar value, the block applies the same offset value to each column of the input data matrix. The offset creates a transient effect, rather than a persistent delay.

Select this parameter to output intermediate cumulative sums between successive resets.

  • If you clear the check box (off), then the block outputs the cumulative sum at each reset time.

    • If the input is a scalar value, then the output sample time is N times the input sample time and the block experiences a delay whose duration is one output sample period. In this case, the output dimensions match the input dimensions.

    • If the input is a (k×N)-by-L matrix, then the output is k-by-L. In this case, the block experiences no delay and the output period matches the input period.

  • If you select the check box (on), then the block outputs the cumulative sum at each time step. The output has the same sample time and the same matrix dimensions as the input.

Fixed-Point Attributes

The settings for the following parameters apply only when block inputs are fixed-point signals.

Data Types

Select the rounding mode for fixed-point operations. The block uses rounding mode when the result of a fixed-point calculation does not map exactly to a number representable by the data type. For more information, see Rounding Modes or Use Simplest Rounding for Efficient Generated Code (Fixed-Point Designer).

Use this parameter to specify the overflow mode to be used if the magnitude of a fixed-point calculation result does not fit into the range of the data type and scaling that stores the result.

  • When you clear the check box (off), the fixed-point calculation wraps on overflow. The wrap uses modulo arithmetic to cast an overflow back into the representable range of the data type. For more information, see Modulo Arithmetic (Fixed-Point Designer).

  • When you select the check box (on), the fixed-point calculation saturates on overflow. The saturation represents positive overflows as the largest positive number in the range being used, and negative overflows as the largest negative number in the range being used.

Specify the accumulator word and fraction lengths. For diagrams showing the use of the accumulator data type in this block, see the filter structure diagrams for the Discrete FIR Filter (Simulink) block and Multiplication Data Types.

  • When you select Inherit: Inherit via internal rule, the block inherits the data type based on an internal rule. For more information on this rule, see Inherit via Internal Rule.

  • When you select Inherit: Same as input, these characteristics match those of the input to the block.

  • When you select Binary point scaling, enter the word length and the fraction length of the output, in bits.

For information about specifying data types, see Data Type Assistant.

Specify the output word and fraction lengths.

  • When you select Inherit: Same as input, these characteristics match those of the input to the block.

  • When you select Inherit: Same as accumulator, these characteristics match those of the accumulator.

  • When you select Binary point scaling, enter the word length and the fraction length of the output, in bits.

For information about specifying data types, see Data Type Assistant.

Block Characteristics

Data Types

double | fixed point | single

Multidimensional Signals

no

Variable-Size Signals

no

More About

expand all

Extended Capabilities

expand all

C/C++ Code Generation
Generate C and C++ code using Simulink® Coder™.

Version History

Introduced before R2006a