DSP Blockset | ![]() ![]() |
Unwrap an input containing radian phase angles.
Library
Description
The Unwrap block removes phase discontinuities in each column of the M-by-N input matrix, u, by adding or subtracting an appropriate multiple of 2 to each element. The block recognizes a phase discontinuity, or phase jump, whenever a given input element, ui,j, differs from the preceding element in the same column by an absolute amount greater than the absolute value of the specified Tolerance parameter,
.
To eliminate the jumps in the input, the block scans down each column and adds 2k to all elements following a jump (including the discontinuous element itself). The value of k is initialized to 0, and is then incremented by 1 for each successive negative jump in the column (
;
), and decremented by 1 for each successive positive jump in the column (
;
).
The value of k is reset to 0 for each successive sample-based input. For frame-based inputs, the value of k is retained across successive inputs so that unwrapping can proceed continuously across the frame breaks.
The figure below illustrates a single channel being unwrapped with the default Tolerance setting of . The block recognizes a negative jump of 2
when the ascending sequence of radian phase angles rolls around from
to -
. Beginning with the -
element, the block adds 2
to all subsequent values in the column. If another negative jump is detected in the same column, the block adds 4
to all subsequent values, and so on.
The output has the same dimension and frame status as the input. For convenience, length-M 1-D vector inputs and sample-based length-M row vector inputs are both treated as M-by-1 column vectors, and the output retains the dimensions of the input.
Dialog Box
See Also
unwrap |
MATLAB |
![]() | Uniform Encoder | Upsample | ![]() |