# How to write huffman coding algorithm without using huffmanenco & huffmandeco ?

Status
Not open for further replies.

#### valentinacruise

##### Newbie level 1
i should code the huffman coding without matlab codes (huffenco and deco). i mean i should write huffmanenco & huffmanenco myself. can any body help me?

#### weetabixharry

##### Full Member level 4
Re: How to write huffman coding algorithm without using huffmanenco & huffmandeco ?

Why should you write them yourself? They are already written and working. If you mean you want to be able to see the source code yourself, just type the following into Matlab:

Code Matlab M - [expand]1
2
edit huffmanenco
edit huffmandeco

There will be some extra error-checking stuff that you probably won't really need... but you can strip down the code however you want.

Alternatively, note that these functions have been implemented in GNU Octave (the free, open source version of Matlab). Because it is open source, you can freely access the code online:

https://sourceforge.net/p/octave/communications/ci/default/tree/inst/huffmanenco.m
https://sourceforge.net/p/octave/communications/ci/default/tree/inst/huffmandeco.m

Status
Not open for further replies.