You are here : matlab → Signal Processing → unwrap
# unwrap() - Signal Processing

### Syntax

### Example

### Output / Return Value

### Limitations

### Alternatives / See Also

### Reference

Q = unwrap(P) corrects the radian phase angles in a vector P by adding multiples of ±2π when absolute jumps between consecutive elements of P are greater than or equal to the default jump tolerance of π radians. If P is a matrix, unwrap operates columnwise. If P is a multidimensional array, unwrap operates on the first nonsingleton dimension.Q = unwrap(P,tol) uses a jump tolerance tol instead of the default value, π.Q = unwrap(P,[],dim) unwraps along dim using the default tolerance.Q = unwrap(P,tol,dim) uses a jump tolerance of tol. Note A jump tolerance less than π has the same effect as a tolerance of π. For a tolerance less than π, if a jump is greater than the tolerance but less than π, adding ±2π would result in a jump larger than the existing one, so unwrap chooses the current point. If you want to eliminate jumps that are less than π, try using a finer grid in the domain.

Q = unwrap(P)Q = unwrap(P,tol)Q = unwrap(P,[],dim)Q = unwrap(P,tol,dim)

w = [0:.2:3,3.5:1:10]; p = [ 0 -1.5728 -1.5747 -1.5772 -1.5790 -1.5816 -1.5852 -1.5877 -1.5922 -1.5976 -1.6044 -1.6129 -1.6269 -1.6512 -1.6998 -1.8621 1.7252 1.6124 1.5930 1.5916 1.5708 1.5708 1.5708 ]; semilogx(w,p,'b*-'), hold