Fixed-Point Blockset    
Integrator Trapezoidal

Perform discrete-time integration of a signal using the trapezoidal method

Library

Calculus

Description

The Integrator Trapezoidal block performs a discrete-time integration of a signal using the trapezoidal method. At time step k, the block computes the average of the inputs at times k-1 and k, multiplies the average by the weighted sample time, and adds the result to the cumulative sum since time zero. The block outputs the sum up to the kth time step at time.

The block calculates the output at time k by the rule

where is the input at time k and

At the first time step, y(0) is set to the value of Initial condition for previous output, and w(0) is set to the value of Initial condition for previous weighted input K*Ts*u/2.

Parameters and Dialog Box

Gain value
Specify the weight by which the sample time is multiplied.
Initial condition for previous output
Set the initial condition for the previous output.
Initial condition for previous weighted input K*Ts*u/2
Set the initial condition for the previous weighted input.
Output data type and scaling
The options are:
Round toward
Rounding mode for the fixed-point output.
Saturate to max or min when overflows occur
If selected, fixed-point overflows saturate.

Characteristics

Input Port
Any data type supported by the blockset
Output Port
Same as the input
Direct Feedthrough
Yes
Scalar Expansion
Of inputs and gain

See Also

Integrator Backward, Integrator Backward Resettable, Integrator Backward Resettable Limited, Integrator Forward, Integrator Forward Resettable, Integrator Forward Resettable Limited, Integrator Trapezoidal Resettable, Integrator Trapezoidal Resettable Limited


  Integrator Forward Resettable Limited Integrator Trapezoidal Resettable