|
Contents | Previous | Next | Subchapters |
| Syntax |
r = unwrap(a) |
r = unwrap(a, b) | |
r = unwrap(a, b, d) | |
| See Also | mod , colunmod |
2 pi.
If the argument b is not present
or if it is an empty matrix,
the value pi is used in its place.
If the argument b is present,
it must be an integer, real or double-precision
scalar greater than zero.
The return value r
satisfies the following properties:
( R - X ) / (2 pi)
k k
is equal to an integer and
| R - R | < 2 pi
k+1 k
furthermore
if X - X > +b then R - R < 0
k+1 k k+1 k
if X - X < -b then R - R > 0
k+1 k k+1 k
where X and R depend on x and d
as follows
| d | x |
X
|
R | |||||||||
| not present | a row vector | equal x | equal r not present | not a row vector | any column of x | any column of r equal 1 | any value | any column of x | any column of r equal 2 | any value | any row of x | any row of r |
x = 2 * seq(5)
y = 2 * PI
x = mod(x, y)
print x
O-Matrix will respond
{
2
4
6
1.71681
3.71681
}
If you continue by entering
x = unwrap(x)
print x
O-Matrix will respond
{
2
4
6
8
10
}