subject

Part I: Write a program to compress a source file into a target file using the Huffman coding method. First, use ObjectOutputStream to output the Huffman codes into the target file, then use BitOutputStream from Assignment #2 to output the encoded binary contents to the target file. Pass the files from the command line using something like the following command: C:\Users\ > java Compress_a_File sourceFile. txt compressedFile. txt
When I did this for my source file, I got a compressed file that looked something like the following:
¬í w Zur [Ljava. lang. String;­ÒVçé{G xp t 01101ppt 11010t 100t 10101pt 1111010t 011000t 1010011pt 1111011pt 1101110t 110110t 1101111t 00000t 01111t 010t 101000pt 00001t 11111ppt 01110t 00010t 00011t 1110t 111100pt 1011t 001t 1100t 011001pppt 1010010 û§Åµ©iõÓwœ°Í­MîeWM÷t¦tËDÌÌ£îUÓXæ=…å ¢gògw
Part II: Write a second program, Decompress_a_File. java, to decompress a previously compressed file so that it replicates the original source file in Part I above. You would do this at the command line with a command that looks like the following:
C:\Users\...> java Decompress_a_File compressedFile. txt decompressedFile. txt
When I ran this second program on my compressed file from Part I above I got:
Roses are red,
Violets are blue,
Try to compress this file,
And then decompress it too.
All groups will consist of 4-5 students, who will be assigned to their groups by the instructor. Groups will be further broken into subgroups, i. e., 2-3 students will be responsible for Part I to compress a source file, and 2 students will assume responsibility for Part II of the project to decompress a compressed file. Both subgroups will be responsible for ensuring that both parts are in synch.

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 14:30
The basic work area of the computer is it screen that you when you first fire up your computer
Answers: 1
question
Computers and Technology, 23.06.2019 19:00
Now you’re on your own. include a short summary of this section with plots in your lab report. write a matlab script file to do steps (a) through (d) below. include a listing of the script file with your report. 1 the soundsc(xx,fs) function requires two arguments: the first one (xx) contains the vector of data to be played, the second argument (fs) is the sampling rate for playing the samples. in addition, soundsc(xx,fs) does automatic scaling and then calls sound(xx,fs) to actually play the signal. mcclellan, schafer, and yoder, dsp first, 2e, isbn 0-13-065562-7. prentice hall, upper saddle river, nj 07458. c 2015 pearson education, inc. 4 mcclellan, schafer and yoder, signal processing first. prentice hall, upper saddle river, new jersey, 2003. c 2003 prentice hall. (a) generate a time vector (tt) to cover a range of t that will exhibit approximately two cycles of the 4000 hz sinusoids defined in the next part, part (b). use a definition for tt similar to part 2.2(d). if we use t to denote the period of the sinusoids, define the starting time of the vector tt to be equal to t , and the ending time as ct . then the two cycles will include t d 0. finally, make sure that you have at least 25 samples per period of the sinusoidal wave. in other words, when you use the colon operator to define the time vector, make the increment small enough to generate 25 samples per period. (b) generate two 4000 hz sinusoids with arbitrary amplitude and time-shift. x1.t / d a1 cos.2
Answers: 1
question
Computers and Technology, 24.06.2019 01:00
The initial tableau of a linear programming problem is given. use the simplex method to solve it. x 1 x 2 x 3 s 1 s 2 z 1 2 4 1 0 0 8 3 4 1 0 1 0 10 minus3 minus12 1 0 0 1 0 the maximum is nothing when x 1equals nothing, x 2equals nothing, x 3equals nothing, s 1equals3, and s 2equals0. (be sure to simplify to lowest terms if necessary.)
Answers: 2
question
Computers and Technology, 24.06.2019 01:30
How can you make your column headings stand out?
Answers: 1
You know the right answer?
Part I: Write a program to compress a source file into a target file using the Huffman coding method...
Questions
question
Biology, 03.12.2020 01:00
question
Mathematics, 03.12.2020 01:00
question
Mathematics, 03.12.2020 01:00
question
Mathematics, 03.12.2020 01:00
question
Mathematics, 03.12.2020 01:00
question
English, 03.12.2020 01:00
question
Mathematics, 03.12.2020 01:00
Questions on the website: 13722361