Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

neeed MATLAB code asap In this project, you will create a simulation using Huffman Code to calculate the average length and entropy H(X), given the

image text in transcribed

image text in transcribed

neeed MATLAB code asap

In this project, you will create a simulation using Huffman Code to calculate the average length and entropy H(X), given the number of symbols and probabilities of those symbols. A table for the symbols and probabilities is shown below: Symbol x1 x2 x3 x4 x5 x6 x7 x8 x9 x10 Probability 0.4 0.2 0.1 0.1 0.05 0.05 0.025 0.025 0.025 0.025 Average length and entropy equations are given as: L = average length of the code Pili Length code H(x)= - Pi Log Pi Entropy For this project, you will need to: 1) Simulate Huffman Code to produce code words for each of the symbols in the table. 2) Find the entropy H(X), using its respective equation. 3) Find the average length, using its respective equation and the code word lengths found. 4) Compare entropy and average length, verifying that H(X) is less than or equal to average length. The code can either be written in C. Matlab, or python. In this project, you will create a simulation using Huffman Code to calculate the average length and entropy H(X), given the number of symbols and probabilities of those symbols. A table for the symbols and probabilities is shown below: Symbol x1 x2 x3 x4 x5 x6 x7 x8 x9 x10 Probability 0.4 0.2 0.1 0.1 0.05 0.05 0.025 0.025 0.025 0.025 Average length and entropy equations are given as: L = average length of the code Pili Length code H(x)= - Pi Log Pi Entropy For this project, you will need to: 1) Simulate Huffman Code to produce code words for each of the symbols in the table. 2) Find the entropy H(X), using its respective equation. 3) Find the average length, using its respective equation and the code word lengths found. 4) Compare entropy and average length, verifying that H(X) is less than or equal to average length. The code can either be written in C. Matlab, or python

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Pro PowerShell For Database Developers

Authors: Bryan P Cafferky

1st Edition

1484205413, 9781484205419

Students also viewed these Databases questions

Question

=+ Judgmental assessment: personal experience or outside experts?

Answered: 1 week ago

Question

1. Write down two or three of your greatest strengths.

Answered: 1 week ago