|
Contents | Previous | Next | Subchapters |
| Syntax |
h = hankel(c) |
h = hankel(c, r) | |
| See Also | hilb |
If m is the length of the vector c
and n is the length of the vector r,
the return value h is the m x n matrix defined by
/ c(i + j - 1) if i + j - 1 < m
h(i, j) = <
\ r(i + j - m) otherwise
Note that the first element of r is never used.
If the argument r is not present, the integer zero vector
with the same length as c is used in its place.
c = 1 : 1 : 3
hankel(c)
O-Matrix will reply
{
[ 1 , 2 , 3 ]
[ 2 , 3 , 0 ]
[ 3 , 0 , 0 ]
}
If you continue by entering
r = 4 : -1 : 1
hankel(c, r)
O-Matrix will reply
{
[ 1 , 2 , 3 , 3 ]
[ 2 , 3 , 3 , 2 ]
[ 3 , 3 , 2 , 1 ]
}