Function Index
DiscreteHadamardTransform
DiscreteHadamardTransform[
img
]
returns the discrete Hadamard transform (DHT) of
img
.
DiscreteHadamardTransform[
img
,
{n
1
,
n
2
,
...}
]
returns the DHT of a zero-padded
img
with dimensions n
1
×n
2
×....
The 1D DHT of a sequence x[n] is defined as
for k = 0,1,...,N-1, with N=2
m
where
m
is an integer.
The 2D DHT of a sequence x[n
1
,n
2
] is defined as
for k
1
= 0, 1, ... , N
1
-1 and k
2
= 0, 1,..., N
2
-1, where N
1
= 2
m
1
, N
2
=2
m
2
, m
1
, and m
2
are integers, and b
i
(z) is the
i-
th bit in the binary representation of
z
. The addition of the bits b
i
in the exponent of -1 is in modulo-2 arithmetic. Note that the forward and inverse Hadamard transforms are identical.
The option
SequencyOrdered→True
returns the ordered form of the Hadamard transform. The default value is
SequencyOrdered→False
.
The argument
img
may be a vector, matrix, or
ImageData
expression.
See also User's Guide
8.5
.
Example
This loads the package.
In[1]:=
This computes and displays the DHT of a 2D sequence that depicts a white rectangle on a black background.
In[2]:=
Here we show the result of computing an ordered Hadamard transform of the sequence.
In[3]:=
© 2008 Wolfram Research, Inc.
•
Terms of Use
•
Privacy Policy
Sign up for our newsletter: