[Israel.pm] binary vectors representation

semuel semuel at semuel.co.il
Sun Jun 13 08:22:13 PDT 2004

Hello There.

RLE is to encode sequences. 
The method, in your case, is that:
'0' and '1' represent themselves, every other number (up to 255) represent a
sequence of zeros, with that length. 
If you have 50,000 zeros with about 50 ones inside, you'll get encoding to
about 250 bytes. (50,000/255 =~ 200, +50 ones.)
Easy to encode, easy to expand.


-----Original Message-----
From: Shlomo Yona [mailto:shlomo at cs.haifa.ac.il] 
Sent: Sunday, June 13, 2004 3:23 PM
To: semuel at semuel.co.il; Perl in Israel
Subject: RE: [Israel.pm] binary vectors representation

On Sun, 13 Jun 2004, semuel wrote:

> Hello There.
> What about RLE? (Run-Length-Encoding)
> Can be a good cast for this.

What is it?

Shlomo Yona
shlomo at cs.haifa.ac.il

More information about the Perl mailing list