aberaud / base91-python

A python implementation of Base91 as described on http://base91.sourceforge.net/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How does the B91 system actually work?

DonaldTsang opened this issue · comments

I know that Base85 treats each 4 Bytes as a set. How many Bytes does Base91 treats as a set?

Base91 packs 13 bits using 16 bits : in 16 bits you can pack 91*91 different values = 8281 > 2^13 = 8192.

From the sourceforge page:
"basE91 is an advanced method for encoding binary data as ASCII characters. It is similar to UUencode or base64, but is more efficient. The overhead produced by basE91 depends on the input data. It amounts at most to 23% (versus 33% for base64) and can range down to 14%, which typically occurs on 0-byte blocks. This makes basE91 very useful for transferring larger files over binary unsafe connections like e-mail or terminal lines."