Previous: DWT in one dimension, Up: DWT Transform Functions
The library provides functions to perform two-dimensional discrete wavelet transforms on square matrices. The matrix dimensions must be an integer power of two. There are two possible orderings of the rows and columns in the two-dimensional wavelet transform, referred to as the “standard” and “non-standard” forms.
The “standard” transform performs a complete discrete wavelet transform on the rows of the matrix, followed by a separate complete discrete wavelet transform on the columns of the resulting row-transformed matrix. This procedure uses the same ordering as a two-dimensional fourier transform.
The “non-standard” transform is performed in interleaved passes on the rows and columns of the matrix for each level of the transform. The first level of the transform is applied to the matrix rows, and then to the matrix columns. This procedure is then repeated across the rows and columns of the data for the subsequent levels of the transform, until the full discrete wavelet transform is complete. The non-standard form of the discrete wavelet transform is typically used in image analysis.
The functions described in this section are declared in the header file gsl_wavelet2d.h.
These functions compute two-dimensional in-place forward and inverse discrete wavelet transforms in standard and non-standard forms on the array data stored in row-major form with dimensions size1 and size2 and physical row length tda. The dimensions must be equal (square matrix) and are restricted to powers of two. For the
transform
version of the function the argument dir can be eitherforward
(+1) orbackward
(-1). A workspace work of the appropriate size must be provided. On exit, the appropriate elements of the array data are replaced by their two-dimensional wavelet transform.The functions return a status of
GSL_SUCCESS
upon successful completion.GSL_EINVAL
is returned if size1 and size2 are not equal and integer powers of 2, or if insufficient workspace is provided.
These functions compute the two-dimensional in-place wavelet transform on a matrix a.
These functions compute the two-dimensional wavelet transform in non-standard form.
These functions compute the non-standard form of the two-dimensional in-place wavelet transform on a matrix a.