Huffman Codes Analysis of Algorithms Prof. Muhammad Saeed 1.

Slides:



Advertisements
Similar presentations
TWO STEP EQUATIONS 1. SOLVE FOR X 2. DO THE ADDITION STEP FIRST
Advertisements

Who Wants To Be A Millionaire?
Welcome to Who Wants to be a Millionaire
Introduction to Algorithms
Question??? What is a prime factor?
Whether it rains, Whether it pours, Wherever I go,
Slide 1 Insert your own content. Slide 2 Insert your own content.
1 Copyright © 2010, Elsevier Inc. All rights Reserved Fig 3.1 Chapter 3.
1 Chapter 58 - Clinical Syndromes of Metabolic Alkalosis Copyright © 2013 Elsevier Inc. All rights reserved.
1 Copyright © 2013 Elsevier Inc. All rights reserved. Chapter 14.
Quest ion 1? A.) answer B.) answer C.) correct answerD.) answer L C.) correct answer F.
Combining Like Terms. Only combine terms that are exactly the same!! Whats the same mean? –If numbers have a variable, then you can combine only ones.
Jeopardy Q 1 Q 6 Q 11 Q 16 Q 21 Q 2 Q 7 Q 12 Q 17 Q 22 Q 3 Q 8 Q 13
Jeopardy Q 1 Q 6 Q 11 Q 16 Q 21 Q 2 Q 7 Q 12 Q 17 Q 22 Q 3 Q 8 Q 13
0 - 0.
DIVIDING INTEGERS 1. IF THE SIGNS ARE THE SAME THE ANSWER IS POSITIVE 2. IF THE SIGNS ARE DIFFERENT THE ANSWER IS NEGATIVE.
MULTIPLYING MONOMIALS TIMES POLYNOMIALS (DISTRIBUTIVE PROPERTY)
ADDING INTEGERS 1. POS. + POS. = POS. 2. NEG. + NEG. = NEG. 3. POS. + NEG. OR NEG. + POS. SUBTRACT TAKE SIGN OF BIGGER ABSOLUTE VALUE.
MULTIPLICATION EQUATIONS 1. SOLVE FOR X 3. WHAT EVER YOU DO TO ONE SIDE YOU HAVE TO DO TO THE OTHER 2. DIVIDE BY THE NUMBER IN FRONT OF THE VARIABLE.
SUBTRACTING INTEGERS 1. CHANGE THE SUBTRACTION SIGN TO ADDITION
MULT. INTEGERS 1. IF THE SIGNS ARE THE SAME THE ANSWER IS POSITIVE 2. IF THE SIGNS ARE DIFFERENT THE ANSWER IS NEGATIVE.
Teacher Name Class / Subject Date A:B: Write an answer here #1 Write your question Here C:D: Write an answer here.
Addition Facts
Functional Programming Lecture 15 - Case Study: Huffman Codes.
CS4026 Formal Models of Computation Running Haskell Programs – power.
MINAP: DATA HANDLING PROCEDURES & DATA ACCESS Data Management Group, 13 July 2009.
How well do you KNOW your 2 times table ? Play the following game Are you ready ? X MULTIPLYTIMES PRODUCT.
Empty Box Problems Subtraction = 3 If you start on 6 and jump back 3 spaces you land on
Improving Compression Ratio, Area Overhead, and Test Application Time in System-on-a-chip Test Data Compression/Decompression Paul Theo Gonciari*, Bashir.
BALANCING 2 AIM: To solve equations with variables on both sides.
Welcome to Who Wants to be a Millionaire
BALANCING EQUATIONS AIM: Solve equations with variables on both sides.
Treasure Map By: Gage Gwin Haven Beagle START. Step 1 23 tiles south CONTINUE.
1 Symbol Tables. 2 Contents Introduction Introduction A Simple Compiler A Simple Compiler Scanning – Theory and Practice Scanning – Theory and Practice.
O X Click on Number next to person for a question.
© S Haughton more than 3?
Programación. Unidad 2 Operadores Operadores de asignación 1.= 2.+= 3.-= 4.*= 5./= 6.%= 7.>>= 8.
5.9 + = 10 a)3.6 b)4.1 c)5.3 Question 1: Good Answer!! Well Done!! = 10 Question 1:
Name Convolutional codes Tomashevich Victor. Name- 2 - Introduction Convolutional codes map information to code bits sequentially by convolving a sequence.
1 Directed Depth First Search Adjacency Lists A: F G B: A H C: A D D: C F E: C D G F: E: G: : H: B: I: H: F A B C G D E H I.
Squares and Square Root WALK. Solve each problem REVIEW:
Past Tense Probe. Past Tense Probe Past Tense Probe – Practice 1.
Limits (Algebraic) Calculus Fall, What can we do with limits?
Properties of Exponents
Addition 1’s to 20.
25 seconds left…...
Bab /44 Bab 4 Classification: Basic Concepts, Decision Trees & Model Evaluation Part 1 Classification With Decision tree Muhamad Arief Hidayat
Test B, 100 Subtraction Facts
Click your mouse to move the card ahead! Work with a buddy using two Abacuses. First click and follow along using your abacus. After each click talk about.
11 = This is the fact family. You say: 8+3=11 and 3+8=11
Week 1.
1 Ke – Kitchen Elements Newport Ave. – Lot 13 Bethesda, MD.
Bottoms Up Factoring. Start with the X-box 3-9 Product Sum
O X Click on Number next to person for a question.
Use addition to eliminate a variable
©2004 Brooks/Cole FIGURES FOR CHAPTER 14 DERIVATION OF STATE GRAPHS AND TABLES Click the mouse to move to the next page. Use the ESC key to exit this chapter.
CREATING a HUFFMAN CODE EVERY EGG IS GREEN E ///// V/V/ R // Y/Y/ I/I/ S/S/ N/N/ Sp /// V/V/ Y/Y/ I/I/ S/S/ N/N/ R // Sp /// G /// E /////
Optimal Merging Of Runs
Dr. O.Bushehrian ALGORITHM DESIGN HUFFMAN CODE. Fixed length code a: 00b: 01c: 11 Given this code, if our file is ababcbbbc our encoding is
Introduction to Algorithms Chapter 16: Greedy Algorithms.
Lossless Decomposition and Huffman Codes Sophia Soohoo CS 157B.
Huffman Coding The most for the least. Design Goals Encode messages parsimoniously No character code can be the prefix for another.
Huffman encoding.
Assignment 6: Huffman Code Generation
Data Compression If you’ve ever sent a large file to a friend, you may have compressed it into a zip archive like the one on this slide before doing so.
Math 221 Huffman Codes.
Huffman Encoding Huffman code is method for the compression for standard text documents. It makes use of a binary tree to develop codes of varying lengths.
Trees Addenda.
CSE 326 Huffman coding Richard Anderson.
Presentation transcript:

Huffman Codes Analysis of Algorithms Prof. Muhammad Saeed 1

CharacterCodeFrequencyTotal Bits a e i s01139 t space newline11013 Total Standard Coding Scheme Table Code length=3 Tree Analysis of Algorithms 2

CharacterCodeFrequencyTotal Bits a e i s01139 t space newline11012 Total Standard Coding Scheme Tree Table Code length=3 Analysis of Algorithms 3

CharacterCodeFrequencyTotal Bits a e i s t space newline Total Standard Coding Scheme Table Variable Code Length Tree Analysis of Algorithms 4 Prefix Code

CharacterCodeFrequencyTotal Bits a e i s t space newline Total Standard Coding Scheme Table Formation of Tree and Code generation Analysis of Algorithms 5

CharacterCodeFrequencyTotal Bits a e i s t space newline Total Standard Coding Scheme Table Formation of Tree and Code generation Analysis of Algorithms 6

CharacterCodeFrequencyTotal Bits a e i s t space newline Total Standard Coding Scheme Table Formation of Tree and Code generation Analysis of Algorithms 7

CharacterCodeFrequencyTotal Bits a e i s t space newline Total Standard Coding Scheme Table Formation of Tree and Code generation Analysis of Algorithms 8

CharacterCodeFrequencyTotal Bits a e i s t space newline Total Standard Coding Scheme Table Formation of Tree and Code generation Analysis of Algorithms 9

CharacterCodeFrequencyTotal Bits a e i s t space newline Total Standard Coding Scheme Table Formation of Tree and Code generation Analysis of Algorithms 10

CharacterCodeFrequencyTotal Bits a e i s t space newline Total Standard Coding Scheme Table Analysis of Algorithms 11 Formation of Tree and Code generation

Analysis of Algorithms 12

Analysis of Algorithms 13 SymbolProbabilityCodeword K L0.201 U W E0.311 R0.200 ? Example:

End Huffman Codes Analysis of Algorithms 14