Department of Scientific Computing   
Institute for Numerical Simulation   
University of Bonn   
Documentation
Download
Programming References
Bug Reports / Suggestions
FAQ
Authors
next up previous
Next: Wavelet Transform for Orthogonal Up: Examples Previous: Examples


Wavelet Transforms

The following example generates the nodal values of the function $f(x,y)=(1e-8 + (x-3/9)^2 + (y-4/9)^2)^ {1/4}$ on a 129x129 grid. Thes nodal values are the scaling function coefficients of 4th order Interpolets. Then, these coefficients are transformed to obtain the wavelet coefficients. First a transform according to the Meyer-construction and then according to the anisotropic tensor product construction. The source to this example is Sources/Examples/WT.cc. You can compile it by make WT in the Examples directory.

see the code WT.cc

WT.exe produces three files which contain nodal values of F and wavelet coefficients respectively. Visualize the results in MATLAB by (AWFD/Sources/Examples/wt.m). Do not forget to add AWFD/MATLAB/Sources/ to the MATLABPATH environment variable!

A=ReadUDF('../../Data/Test/A') ;
B=ReadUDF('../../Data/Test/B') ;
C=ReadUDF('../../Data/Test/C') ;
figure(1); surf(A.a) ;shading flat
figure(2); pcolor(log(abs(B.a))) ;shading flat; title 'Meyer-wavelets'
figure(3); pcolor(log(abs(C.a))) ;shading flat; title 'Anisotropic tensor product wavelets'

You should get the following three figures. The blue regions in figures 2 and 3 correspond to very small wavelet coefficients. Obviously there are many more small wavelet coefficients for the tensor product transform (figure 3) than for the Meyer-wavelets (figure 2). This simply means, that the anisotropic wavelets lead to a much more compact representation of the function, since the information is localized in a smaller number of large wavelet coefficients. That's essentially the idea why AWFD uses these wavelets for the solvers.

1775 1776 1777


next up previous
Next: Wavelet Transform for Orthogonal Up: Examples Previous: Examples
koster 2003-07-29