\setcounter{equation}{0}\section{Numerical Results }

We have carried out experiments with $W$-matrix transforms, in particular,
comparing the quadratic spline (QS) 
and $ D_4 $  transforms in compressing 
various types of signals.  Our conclusion is that
for reasonably smooth signals, with occasional 
jumps, QS outperforms $ D_4 $.  
The situation is reversed for signals
having high levels of high-frequency components
or random noise.  This fact does not indicate weakness of
the QS transform, however.  It means only that
the transform tends to filter out high-frequency 
components and noise, to which most human eyes and ears
are insensitive.  More experiments
are needed to test the physiological aspects
on observers.

\subsection{One-dimensional Signals}

In the experiments reported below, 
an input signal \bdx\ is decomposed
into $ \yo $ and $ \yt $ using, in turn, the QS and $ D_4 $  transforms.  
A certain number $ N $ of the largest (in absolute value)
components of $ \yt $ are retained, and an approximation to the
original signal is obtained by using $ \yo $ and the compressed
$ \yt $.  The relative errors between the original and 
the restored
approximation, measured using the Euclidean $ l^2 $ norm,
are given.  

Our first example uses the signal
$  \bdx = \sin( (1\mbox{:}100)/10 )+0.2\sin( (1\mbox{:}100)/2 ) $,
where $ 1\mbox{:}100 $ denotes the vector
$ [1,2,3,\cdots ,100] $.
In Table 2, the first column gives the
number of components in $ \yt $ that are retained.
The third and fourth columns
give the relative $ l^2 $ error of the restored signal, for
the QS and $ D_4 $  transforms, respectively.
The second column gives the error of the restored signal
using the QS transform with orthogonal compensation,
an additional step (explained in Section~5) that
can be applied to reduce the error.

The original signal is plotted in Figure 1 alongside
the two approximate signals, restored by using the largest
three components of $ \yt $.  To display the graphs better, 
we displaced the restored signals by $ \pm 0.2 $,
respectively --- the middle graph is the original signal, the
upper graph is from the QS transform, and the lower
graph is from the $ D_4 $  transform.  
The figure clearly shows that
the $ D_4 $ restored signal has some sharp corners, due to the
non-smoothness of the $ D_4 $ scaling function.  The sharp
corners are even more pronounced when the multiresolution analysis is continued
to higher levels.

\begin{center}
\begin{minipage}{5.2in}
Table 2. Errors in the restored signal from the
QS and $ D_4 $  transforms
\end{minipage}
\end{center}
\begin{center}
% \tabcolsep=13pt
\begin{tabular}{|c|c|c|c||c|c|c|c|}
\hline
$ N $ & QSOC & QS & $D_4$ \vphantom{\LARGE A} & $ N $ & QSOC & Q.S. & $D_4$ \\[.8ex]
\hline\hline     
     3 & 0.003203 &  0.003762    &  0.019268  & 15 &  0.003030 & 0.003255    &  0.013061\\
     5 & 0.003163 &  0.003676    &  0.018245  & 18 &  0.002901 & 0.003067    &  0.011690\\
     8 & 0.003102 &  0.003554    &  0.016651  & 20 &  0.002717 & 0.002848    &  0.010788\\
    10 & 0.003073 &  0.003469    &  0.015579  & 23 &  0.002394 & 0.002496    &  0.009458\\
    13 & 0.003055 &  0.003336    &  0.013983  & 25 &  0.002157 & 0.002248    &  0.008495\\
\hline
\end{tabular}
\end{center}

\begin{center}
%%
 {\mbox{\psfig{file=../ex1.eps,height=1.9in,width=5.2in}}}
\end{center}
\begin{center}
Figure 1. Example 1, $ N=3 $, middle curve -- original signal
\end{center}

The second example uses 
$  \bdx = \sin( (1\mbox{:}100)/10 )+0.2\sin( (1\mbox{:}100) ) $; see Table 3.
Experiments with signals having occasional jumps produce
similar results; see Figure 2.

\begin{center}
\begin{minipage}{5.2in}
Table 3.  Errors in the restored signal from the
QS and $ D_4 $  transforms
\end{minipage}
\end{center}
\begin{center}
% \tabcolsep=13pt
\begin{tabular}{|c|c|c|c||c|c|c|c|}
\hline
$ N $ & QSOC & QS & $D_4$ \vphantom{\LARGE A} & $ N $ & QSOC & Q.S. & $D_4$ \\[.8ex]
\hline\hline 
     3  & 0.031252  & 0.037637     &  0.067649  & 15  & 0.021298 & 0.024515     &  0.048248\\
     5  & 0.029834  & 0.035672     &  0.064475  & 18  & 0.018048 & 0.020580     &  0.043103\\
     8  & 0.027535  & 0.032539     &  0.059749  & 20  & 0.015440 & 0.017590     &  0.039697\\
    10  & 0.025854  & 0.030324     &  0.056537  & 23  & 0.013596 & 0.015300     &  0.034925\\
    13  & 0.023110  & 0.026946     &  0.051601  & 25  & 0.012358 & 0.013816     &  0.031947\\
\hline
\end{tabular}
\end{center}

\begin{center}
%%
 {\mbox{\psfig{file=../ex2.eps,height=1.9in,width=5.2in}}}
\end{center}
\begin{center}
Figure 2. Example 2, $ N=3 $, middle curve -- original signal
\end{center}


Figures 3 shows the results of 
a three-level
compression of the signal in the first example.

\begin{center}
%%
 {\mbox{\psfig{file=../ex5-524.eps,height=1.9in,width=5.2in}}}
\end{center}
\begin{center}
Figure 3. Example 5, three-level compression, fraction of
$ \yt $ retained at the three levels are $ 0.05,0.2,0.4 $, respectively,
middle curve -- original signal
\end{center}


\subsection{Image Compression}

The following figures show how our transform performs in
compressing the ubiquitous Lena image, using  
a three-level
analysis constructed from the 2D version of the QS transform.

% \psdraft
\begin{center}
%%
 {\mbox{\psfig{file=/home/kwong/Wavelet/Matlab/Raw/lena1.ps,width=5in}}}
\end{center}

\begin{center}
Figure 4.  Original Lena image
\end{center}

At each level, four half-sized matrices are produced.  The
first carries the general shape of the original picture, while
the others contain the details.  
Compression is achieved by quantization. In the
particular experiment given here, 
each of the first three submatrices at each level is quantized
with the same quantization level (which is 800, 5000, and
20000 for the three levels, respectively) and the fourth is quantized
at 4 times of that level.  The number of nonzero wavelet coefficients
retained at the three levels are 624, 8138, and 8331, respectively.
Taking into consideration the number of bits needed to store
each number, we estimate that the compression ratio is about
13.5 times.  Entropy coding may be applied to raised the
ratio slightly.

% \psdraft
\begin{center}
%%
 {\mbox{\psfig{file=lena13.ps,width=5in}}}
\end{center}

\begin{center}
Figure 5.  Lena image restored from data compressed 13.5 times
\end{center}
