Implement arithmetic coding using c in linux (1)-specific operations, linux Arithmetic
Reprinted with the source: http://blog.csdn.net/wang_zheng_kai
Enables students to use development tools to compress the learned data.
Tianjin Institute of Industry and Information Technology
This article includes two parts:
Implement arithmetic coding using c in linux (1)-specific operations
Implement arithmetic coding using c in linux (2) -- specific code
Ubuntu14.04 use C language for arithmetic coding (fixed)
1. Open ubuntu14.04. The interface is as follows:
2. Press Ctrl + Alt + t to open Terminal and execute the command ls to view the arithmetic code fixed_arithmetic.c.
3. Execute the following command to compile the code.
4. Generate the executable program fixed_arithmetic.
5. Run the program as follows.
6. Enter the number of source symbols.
7. input the source symbol and Its Probability in sequence
8. Enter the message queue to be compiled and end the input.
9. Press enter to display the compilation and decoding results.