Array-Vector Divide - Divide array by vector along specified dimension

Library

Math Functions / Matrices and Linear Algebra / Matrix Operations

dspmtrx3

Description

The Array-Vector Divide block divides the values in the specified dimension of the N-dimensional input array A by the values in the input vector V.

The length of the input V must be the same as the length of the specified dimension of A. The Array-Vector Divide block divides each element of V by the corresponding element along that dimension of A.

Consider a 3-dimensional M-by-N-by-P input array A(i,j,k) and a P-by-1 input vector V. When the Divide along dimension parameter is set to 2, the output of the block Y(i,j,k) is

where

The output of the Array-Vector Divide block is the same size as the input array, A. When both inputs are sample based, the output is sample based; otherwise, the output is frame based. This block accepts real and complex floating-point and fixed-point input arrays, and real floating-point and fixed-point input vectors.

Fixed-Point Data Types

The following diagram shows the data types used within the Array-Vector Divide block for fixed-point signals.

When the vector V is designated in the block mask, its elements have the data type and scaling that you specify in the Vector (V) parameters on the Fixed-point tab. When the vector comes in through the block port, its elements inherit their data type and scaling from the driving block.

You can set the vector and output data types in the block dialog as discussed below.

Dialog Box

The Main pane of the Array-Vector Divide block dialog appears as follows.

Divide along dimension

Specify the dimension along which to divide the input array A by the elements of vector V.

Vector (V) source

Specify the source of the vector, V. The vector can come from the Input port or from a Dialog parameter.

Vector (V)

Specify the vector, V. This parameter is visible only when you select Dialog parameter for the Vector (V) source parameter.

The Fixed-point pane of the Array-Vector Divide block dialog appears as follows.

Rounding mode

Select the rounding mode for fixed-point operations.

Overflow mode

Select the overflow mode for fixed-point operations.

Vector (V)

Use this parameter to specify how you would like to designate the word and fraction lengths of the elements of the vector, V:

Output

Choose how you specify the output word length and fraction length:

Lock scaling against changes by the autoscaling tool

Select this parameter to prevent any fixed-point scaling you specify in this block mask from being overridden by the autoscaling tool in the Fixed-Point Tool.

Supported Data Types

PortSupported Data Types

A

  • Double-precision floating point

  • Single-precision floating point

  • Fixed point (signed only)

  • 8-, 16-, and 32-bit signed integers

V

  • Double-precision floating point

  • Single-precision floating point

  • Fixed point (signed only)

  • 8-, 16-, and 32-bit signed integers

Output

  • Double-precision floating point

  • Single-precision floating point

  • Fixed point (signed only)

  • 8-, 16-, and 32-bit signed integers

See Also

Array-Vector AddSignal Processing Blockset
Array-Vector MultiplySignal Processing Blockset
Array-Vector SubtractSignal Processing Blockset

  


 © 1984-2008- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS