文件名称:he_fu_man_bian_ma

介绍说明--下载内容均来自于网络,请自行研究使用

假设一个文件中出现了8种符号S0,SQ,S2,S3,S4,S5,S6,S7,那么每种符号要编码,至少需要3bit。假设编码成000,001, 010,011,100,101,110,111。那么符号序列S0S1S7S0S1S6S2S2S3S4S5S0S0S1编码后变成 000001111000001110010010011100101000000001,共用了42bit。我们发现S0,S1,S2这3个符号出现的频率比较大,其它符号出现的频率比较小,我们采用这样的编码方案:S0到S7的码辽分别01,11,101,0000,0001,0010,0011, 100,那么上述符号序列变成011110001110011101101000000010010010111,共用了39bit。尽管有些码字如 S3,S4,S5,S6变长了(由3位变成4位),但使用频繁的几个码字如S0,S1变短了,所以实现了压缩。对于上述的编码可能导致解码出现非单值性:比如说,如果S0的码字为01,S2的码字为011,那么当序列中出现011时,你不知道是S0的码字后面跟了个1,还是完整的一个S2的码字。因此,编码必须保证较短的编码决不能是较长编码的前缀。符合这种要求的编码称之为前缀编码。要构造符合这样的二进制编码体系,可以通过二叉树来实现。-Suppose a file appears in eight kinds of symbols S0, SQ, S2, S3, S4, S5, S6, S7, then each symbol to be encoded, at least 3bit. Suppose encoding 000,001, 010,011,100,101,110,111. Then the symbolic sequence S0S1S7S0S1S6S2S2S3S4S5S0S0S1 encoded into 000001111000001110010010011100101000000001, sharing a 42bit. We found that S0, S1, S2 these three symbols the frequency of relatively large, the other symbols the frequency is relatively small, we have adopted this coding scheme: S0 to S7 of the yards were 01,11,101,0000,0001,0010 Liao , 0011, 100, then the symbol sequence into 011110001110011101101000000010010010111, shared a 39bit. Although some code words, such as S3, S4, S5, S6 was longer (from 3 into a 4-bit), but a few yards of frequently used words, such as S0, S1 shorter, so to achieve the compression. For the above may lead to decode the presence of non-coding single-valued nature: For example, if the S0 code word for the 01, S2 s code word for the 011, then when the sequence appears
(系统自动生成,下载前可以参看下载内容)

下载文件列表

赫夫曼编码程序设计及报告\报文发送及接收算法设计报告.doc

........................\赫夫曼编码\赫夫曼编码\DataSource.h

........................\..........\..........\DataSource.txt

........................\..........\..........\DSoperator.h

........................\..........\..........\head.h

........................\..........\..........\HTNode.h

........................\..........\..........\HToperator.h

........................\..........\..........\test.c

........................\..........\..........\赫夫曼编码.vcproj

........................\..........\..........\赫夫曼编码.vcproj.A9B2CFAC515D4F1.谭毅.user

........................\..........\赫夫曼编码.ncb

........................\..........\赫夫曼编码.sln

........................\..........\赫夫曼编码.suo

........................\..........\赫夫曼编码

........................\赫夫曼编码

赫夫曼编码程序设计及报告

相关说明

  • 本站资源为会员上传分享交流与学习,如有侵犯您的权益,请联系我们删除.
  • 本站是交换下载平台,提供交流渠道,下载内容来自于网络,除下载问题外,其它问题请自行百度更多...
  • 请直接用浏览器下载本站内容,不要使用迅雷之类的下载软件,用WinRAR最新版进行解压.
  • 如果您发现内容无法下载,请稍后再次尝试;或者到消费记录里找到下载记录反馈给我们.
  • 下载后发现下载的内容跟说明不相乎,请到消费记录里找到下载记录反馈给我们,经确认后退回积分.
  • 如下载前有疑问,可以通过点击"提供者"的名字,查看对方的联系方式,联系对方咨询.

相关评论

暂无评论内容.

发表评论

*主  题:
*内  容:
*验 证 码:

源码中国 www.ymcn.org