wavelet
所属分类:matlab编程
开发工具:matlab
文件大小:19496KB
下载次数:9
上传日期:2013-07-09 10:28:07
上 传 者:
张德志张德志
说明: 清华大学小波分析教程
涵盖小波大部分领域
丰富实例
wavelet, matlab
(Tsinghua wavelet wavelet analysis tutorial covers most areas of abundant examples of wavelet, matlab)
文件列表:
10.4\10-4.pdf (150273, 2005-07-07)
10.4\Debug\ex10.exe (233539, 2011-03-24)
10.4\Debug\ex10.ilk (242292, 2011-03-24)
10.4\Debug\ex10.pch (3588456, 2011-03-24)
10.4\Debug\ex10.pdb (435200, 2011-03-24)
10.4\Debug\in.dat (0, 2012-12-20)
10.4\Debug\main.obj (22989, 2011-03-24)
10.4\Debug\vc60.idb (140288, 2012-12-20)
10.4\Debug\vc60.pdb (77824, 2011-03-24)
10.4\ex10.dsp (4260, 2005-06-28)
10.4\ex10.dsw (533, 2005-06-28)
10.4\ex10.exe (233521, 2005-07-06)
10.4\ex10.ncb (50176, 2012-12-20)
10.4\ex10.opt (48640, 2012-12-20)
10.4\ex10.plg (242, 2012-12-20)
10.4\in.dat (2916, 2012-12-20)
10.4\lena.bmp (66614, 2005-06-29)
10.4\main.cpp (7421, 2005-07-06)
10.4\result.dat (2871, 2012-12-20)
10.4\xiaobobao.m (4631, 2007-10-21)
3\d4_draw1.m (340, 2012-10-18)
3\d4_draw2.m (341, 2012-10-18)
4.2\check.m (881, 2012-10-25)
5.1\wavedec.m (0, 2012-11-08)
5.1\wavedec_test.m (429, 2012-11-08)
5.4\EZW-code\checkchildren.m (337, 2012-11-15)
5.4\EZW-code\checkdescendants1.m (487, 2012-11-15)
5.4\EZW-code\dominantpass.m (3946, 2012-11-15)
5.4\EZW-code\ezw.m (4445, 2012-11-15)
5.4\EZW-code\mapping.m (144, 2003-10-06)
5.4\EZW-code\subordinatepass.m (345, 2012-11-15)
5.4\EZW-code\Text3.txt (2405, 2011-03-29)
5.5\5-5.doc (32768, 2005-07-07)
5.5\SPIHT\contents.m (1340, 2004-04-26)
5.5\SPIHT\func_DWT.m (1588, 2004-04-26)
5.5\SPIHT\func_InvDWT.m (1750, 2004-04-26)
5.5\SPIHT\func_Myappcoef2.m (1683, 2004-04-26)
5.5\SPIHT\func_MyDescendant.m (1158, 2004-04-26)
5.5\SPIHT\func_Mywavedec2.m (2127, 2004-04-26)
... ...
这里的每个文件均定义了一个函数:
函数dominantpass实现主扫描
函数subordinatepass实现辅扫描
函数mapping生成一个与图像同样大小、存储着扫描序号的矩阵函数checkdescendantsl查询某点的子孙是否均小于阈值
函数checkchildren将某T型点的子孙全部标识出来
主函数为ezw(X,LEVEL),其中X为待处理的小波系数矩阵,LEVEL为欲编码的次数
具体执行过程:
在MATLAB命令窗口中先输入X矩阵的内容,然后键入ezw(X,LEVEL),LEVEL为某正整数,则会输出每一次编解码的输出结果,以及原系数矩阵、最终重构的矩阵及两者差值。
注:这里的算法与书上的步骤由两点细微的不同:一是对于没有子孙的叶子节点,若其为不重要系数,则用T表示,而书上用Z表示,所以导致一些主扫描表符号的差异;二是没有对重要系数进行重新排序。这些都不会影响到编解码的过程,仅在此作一注明。
程序执行举例:
在命令窗口中输入
>> X=[63 -34 49 10 7 13 -12 7; % 输入系数矩阵X
-31 23 14 -13 3 4 6 -1;
15 14 3 -12 5 -7 3 9;
-9 -7 -14 8 4 -2 3 2;
-5 9 -1 47 4 6 -2 2;
3 0 -3 2 3 -2 0 4;
2 -3 6 -4 3 6 3 6;
5 11 5 6 0 3 -4 4];
>> ezw(X,5) % 对X进行5次ezw编解码
程序的输出显示了每一次编解码的结果:
There are the EZW encoding outputs below
threshold =
32
D =
pnztpttttztttttttptt
S =
1 0 1 0
threshold =
16
D =
npttttttttttttttt
S =
1 0 0 1 1 0
threshold =
8
D =
ppnppnttnnptpttnttttttttptttpttttttttptttttttttttt
S =
Columns 1 through 10
1 0 0 1 1 1 0 1 1 1
Columns 11 through 20
1 0 1 1 0 1 1 0 0 0
threshold =
4
D =
nzptppptpnpttttntttttttppnpppptttttptptttpnp
S =
Columns 1 through 10
1 1 0 1 1 1 1 1 0 1
Columns 11 through 20
1 0 0 1 0 0 0 0 0 1
Columns 21 through 30
1 1 0 1 1 0 1 0 0 0
Columns 31 through 40
1 0 0 1 0 1 0 1 1 0
Column 41
0
threshold =
2
D =
pptnppppttnppnpnnptptpp
S =
Columns 1 through 10
1 0 1 1 1 1 0 0 1 1
Columns 11 through 20
0 1 0 0 0 1 0 1 1 1
Columns 21 through 30
1 1 0 1 0 1 1 0 1 1
Columns 31 through 40
0 0 1 0 0 0 0 0 0 0
Columns 41 through 50
0 1 1 0 1 1 0 1 1 0
Columns 51 through 59
0 1 1 0 0 0 1 1 1
There are the decoding outputs below
Threshold =
32
level =
1
XX =
56 -40 56 0 0 0 0 0
0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0
0 0 0 40 0 0 0 0
0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0
Threshold =
16
level =
2
XX =
60 -36 52 0 0 0 0 0
-28 20 0 0 0 0 0 0
0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0
0 0 0 44 0 0 0 0
0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0
Threshold =
8
level =
3
XX =
62 -34 50 10 0 14 -14 0
-30 22 14 -14 0 0 0 0
14 14 0 -14 0 0 0 10
-10 0 -14 10 0 0 0 0
0 10 0 46 0 0 0 0
0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0
0 10 0 0 0 0 0 0
Threshold =
4
level =
4
XX =
63 -35 49 11 7 13 -13 7
-31 23 15 -13 0 5 7 0
15 15 0 -13 5 -7 0 9
-9 -7 -15 9 5 0 0 0
-5 9 0 47 5 7 0 0
0 0 0 0 0 0 0 5
0 0 7 -5 0 7 0 7
5 11 5 7 0 0 -5 5
Threshold =
2
level =
5
XX =
63 -34 49 10 7 13 -12 7
-31 23 14 -13 3 4 6 0
15 14 3 -12 5 -7 3 9
-9 -7 -14 8 4 -2 3 2
-5 9 0 47 4 6 -2 2
3 0 -3 2 3 -2 0 4
2 -3 6 -4 3 6 3 6
5 11 5 6 0 3 -4 4
initialiamge =
63 -34 49 10 7 13 -12 7
-31 23 14 -13 3 4 6 -1
15 14 3 -12 5 -7 3 9
-9 -7 -14 8 4 -2 3 2
-5 9 -1 47 4 6 -2 2
3 0 -3 2 3 -2 0 4
2 -3 6 -4 3 6 3 6
5 11 5 6 0 3 -4 4
reconstructedimage =
63 -34 49 10 7 13 -12 7
-31 23 14 -13 3 4 6 0
15 14 3 -12 5 -7 3 9
-9 -7 -14 8 4 -2 3 2
-5 9 0 47 4 6 -2 2
3 0 -3 2 3 -2 0 4
2 -3 6 -4 3 6 3 6
5 11 5 6 0 3 -4 4
difference =
0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 1
0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0
0 0 1 0 0 0 0 0
0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0
近期下载者:
相关文件:
收藏者: