🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.mac
Article #39454

Re: compression thoughts

#39454
From: Jurjen N.E. Bos
Date: Thu, 16 Mar 1989 20:21
14 lines
1234 bytes
In article <7390@rosevax.Rosemount.COM> merlyn@ernie.rosemount.com writes:
>btoa/atob is better than binhex, and btoa can be improved upon
>slightly (about 1% smaller).  btoa encodes 4 bytes into 5 base-85
>digits ('!' to 'u') plus 'x' for end of data, and 'z' for 4 bytes of zero.
>It also add a newline every 78 chars to keep mailers happy.
>About 80% of these newlines can be eliminated if, for each line, the
Ok, you asked for it. btoa makes a file 25% longer, right?
An easy computation shows that, using the 94 ASCII characters from "!" to
"~", one can ultimalety get 100*(log 256)/(log 94)-100=22.052% loss.
Now, if you encode 9 bytes into 11 printable characters, you have only
22.222% loss, which is quite close to the theoretical limit.
Who is going to write a program doing this? :-) :-)
-- 
  -- Jurjen N.E. Bos (jurjen@cwi.nl)
Technical Details
Message-ID: <7962@boring.cwi.nl>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!ames!lll-winken!uunet!mcvax!jurjen
References: <7390@rosevax.Rosemount.COM>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!ames!lll-winken!uunet!mcvax!jurjen
From: jurjen@cwi.nl (Jurjen N.E. Bos)
Newsgroups: comp.sys.mac
Subject: Re: compression thoughts
Summary: This is binary-> ascii conversion!
Message-ID: <7962@boring.cwi.nl>
Date: 16 Mar 89 20:21:38 GMT
References: <7390@rosevax.Rosemount.COM>
Organization: CWI, Amsterdam
Lines: 14