Problem 1148. Compression: Encode and Decode

This Challenge is to compress an array created by randi(2^32-1,1000) and then decompress your data file.

The first call will provide the array x. The output is the filename of the data encoded file.

The second call will provide the filename. The output is the numeric array by decoding the file.

Success: File size less than 4,100,000 bytes and a correct decoded array.

Scoring: Scaled file size.

Encode Call:

Input: x % randi(2^32-1,1000)

Output: filename

. .

Decode Call:

Input: filename

Output: x_array

Note: global and persistent are not allowed. Unexpected files will cause a Virus Detect Failure.

Solution Stats

35.48% Correct | 64.52% Incorrect
Last solution submitted on Nov 11, 2014

Problem Comments

Solution Comments

Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

MATLAB Academy

New to MATLAB?

Learn MATLAB today!