c09fzf inserts a selected set of three-dimensional discrete wavelet transform (DWT) coefficients into the full set of coefficients stored in compact form, which may be later used as input to the reconstruction routines
c09fbf or
c09fdf.
c09fzf inserts a selected set of three-dimensional DWT coefficients into the full set of coefficients stored in compact form in a one-dimensional array
c. It is required that
c09fzf is preceded by a call to the initialization routine
c09acf and either the forwards transform routine
c09faf or multi-level forwards transform routine
c09fcf.
Given an initial three-dimensional data set
$A$, a prior call to
c09faf or
c09fcf computes the approximation coefficients (at the highest requested level in the case of
c09fcf) and, seven sets of detail coefficients (at all levels in the case of
c09fcf) and stores these in compact form in a one-dimensional array
c.
c09fyf can then extract either the approximation coefficients or one of the sets of detail coefficients (at one of the levels following
c09fcf)
into a three-dimensional array,
d. Following some calculation on this set of coefficients (for example, denoising), the updated coefficients in
d are inserted back into the full set
c using
c09fzf. Several extractions and insertions may be performed.
c09fbf or
c09fdf can then be used to reconstruct a manipulated data set
$\stackrel{~}{A}$. The dimensions of
d depend on the level extracted and are available from either: the arrays
dwtlvm,
dwtlvn and
dwtlvfr as returned by
c09fcf if this was called first; or, otherwise from
nwct,
nwcn and
nwcfr as returned by
c09acf. See
Section 2.1 in the
C09 Chapter Introduction for a discussion of the three-dimensional DWT.
None.
Note: the following notation is used in this section:
- ${n}_{\mathrm{cm}}$ is the number of wavelet coefficients in the first dimension. Following a call to c09faf (i.e., when ${\mathbf{ilev}}=0$) this is equal to ${\mathbf{nwct}}/(8\times {\mathbf{nwcn}}\times {\mathbf{nwcfr}})$ as returned by c09acf. Following a call to c09fcf transforming nwl levels, and when inserting at level ${\mathbf{ilev}}>0$, this is equal to ${\mathbf{dwtlvm}}\left({\mathbf{nwl}}-{\mathbf{ilev}}+1\right)$.
- ${n}_{\mathrm{cn}}$ is the number of wavelet coefficients in the second dimension. Following a call to c09faf (i.e., when ${\mathbf{ilev}}=0$) this is equal to nwcn as returned by c09acf. Following a call to c09fcf transforming nwl levels, and when inserting at level ${\mathbf{ilev}}>0$, this is equal to ${\mathbf{dwtlvn}}\left({\mathbf{nwl}}-{\mathbf{ilev}}+1\right)$.
- ${n}_{\mathrm{cfr}}$ is the number of wavelet coefficients in the third dimension. Following a call to c09faf (i.e., when ${\mathbf{ilev}}=0$) this is equal to nwcfr as returned by c09acf. Following a call to c09fcf transforming nwl levels, and when inserting at level ${\mathbf{ilev}}>0$, this is equal to ${\mathbf{dwtlvfr}}\left({\mathbf{nwl}}-{\mathbf{ilev}}+1\right)$
If on entry
${\mathbf{ifail}}=0$ or
$\mathrm{-1}$, explanatory error messages are output on the current error message unit (as defined by
x04aaf).
Not applicable.
Background information to multithreading can be found in the
Multithreading documentation.
None.
The following example demonstrates using the coefficient extraction and insertion routines in order to apply denoising using a thresholding operation. The original input data has artificial noise introduced to it, taken from a normal random number distribution. Reconstruction then takes place on both the noisy data and denoised data. The Mean Square Errors (MSE) of the two reconstructions are printed along with the reconstruction of the denoised data. The MSE of the denoised reconstruction is less than that of the noisy reconstruction.