تولید همه کدهای فشرده با محدودیت روی کوچک‌ترین طول‌کد

نوع مقاله : علمی-پژوهشی

نویسندگان

گروه مخابرات، دانشکده برق و کامپیوتر، دانشگاه صنعتی اصفهان، اصفهان، ایران

چکیده

اگرچه با استفاده از الگوریتم هافمن می‌توان کد فشرده (کد با مجموع کرافت مساوی یک) با حداقل افزونگی را برای یک منبع اطلاعات بدون حافظه ساخت، در برخی مسائل لازم می‌شود که ابتدا همه کدهای فشرده ممکن ساخته شوند و بعد از بین آنها کد مناسب با معیار مورد نظر انتخاب شود. به طور خاص اگر طول همه کلمه‌کدهای یک کد فشرده n تایی λ یا بیشتر باشد، آنگاه اختلاف بزرگ‌ترین و کوچک‌ترین طول کلمه‌کد آن به n-2^λ محدود می‌شود و درنتیجه با افزایش مقدار λ می‌توان تفاوت در تاخیر کدبرداری سمبل‌های مختلف منبع را کاهش داد. ساخت چنین کدهایی هدف اصلی این مقاله است و برای این کار الگوریتمی ارائه می‌شود که فقط همین کدها (کدهای فشرده n تایی که طول همه کلمه‌کدهای آنها λ یا بیشتر باشد) را تولید می‌کند. با توجه به تناظری که بین بردارهای چندگانگی کدهای فشرده با برخی دنباله‌های اعداد وجود دارد، شرط لازم و کافی برای اینکه یک دنباله از اعداد متناظر یک کد فشرده که کوتاه‌ترین کلمه کدش حداقل λ بیت باشد را پیدا می‌کنیم. بدین ترتیب با تولید همه دنباله‌های مناسب، همه کدهای فشرده مطلوب ساخته می‌شوند بدون اینکه هیچ کد فشرده دیگری تولید شود. با استفاده از الگوریتم پیشنهادی منابع محاسباتی کمتری برای تولید کدهای مطلوب لازم می‌شود. به‌عنوان مثال برای 3=λ، منابع محاسباتی لازم برای تولید (فقط) کدهای مطلوب، 5 درصد حالتی است که همه کدهای فشرده تولید شوند.

کلیدواژه‌ها

موضوعات


عنوان مقاله [English]

Generating all compact codes with constraint on the smallest codelength

نویسندگان [English]

  • Mohammadali Khosravifard
  • Hamed Narimani
Department of electrical and computer engineering, Isfahan university of technology, Isfahan, Iran
چکیده [English]

Although by employing the Huffman algorithm one can construct the compact code (code with Kraft sum equal to 1) with minimum redundancy for an information source, in some problems it is required to first construct all possible compact codes and then select an appropriate one on the basis of a desired criterion. In particular, if the length of all codewords of an n-tuple compact code is λ or more, then the difference between the largest and the smallest codeword lengths is limited to n-2^λ, and as a result, by considering larger values for λ, the variation in delay of decoding different symbols of the source can be reduced. The main goal of this paper is construction of all such codes and an algorithm is introduced which generates only these codes (i.e., n-tuple compact codes with all codewords of length λ or more). Noting the correspondence between the multiplicity vectors of the compact codes and some sequences of numbers, we find the necessary and sufficient condition that a sequence of numbers is correspondent with a compact code with the shortest codeword at least λ bits long. This way by generating all suitable sequences, all the desired compact codes can be constructed without generating any other compact code. Using the proposed algorithm, less computational resources are required. For example, for λ=3, the required computational resources for generating only the desired compact codes are 5 percent of those when all compact codes are generated.

کلیدواژه‌ها [English]

  • Compact code
  • Kraft sum
  • Huffman code
  • multiplicity vector
  • smallest codeword length
  • redundancy