[NTG-pdftex] [Fwd: [Dev-luatex] What is the unit "nc" supposed to be?]
Taco Hoekwater
taco at elvenkind.com
Tue Apr 3 11:34:23 CEST 2007
The following is forwarded from the LuaTeX list.
-------- Original Message --------
Subject: [Dev-luatex] What is the unit "nc" supposed to be?
Date: Tue, 03 Apr 2007 11:25:34 +0200
From: David Kastrup <dak at gnu.org>
To: dev-luatex at ntg.nl
New Cicero or what?
Please consider the following:
This is luaTeX, Version 3.141592-snapshot-2007040210 (Web2C 7.5.6)
**\dimen0=1nc
*\showthe\dimen0
> 12.80373pt.
<*> \showthe\dimen0
?
*\dimen0=0.99998nc
*\showthe\dimen0
> -0.09723pt.
<*> \showthe\dimen0
?
*
This does not cut it at all. The section in tex.web starts with
@ The necessary conversion factors can all be specified exactly as
fractions whose numerator and denominator are 32768 or less.
In LuaTeX, the section brazenly starts with
@ The necessary conversion factors can all be specified exactly as
fractions whose numerator and denominator are 65535 or less.
Who does things like that without actually checking that they work?
It is possible to rework the arithmetic to get along with 65535, but
it is certainly not a matter of merely changing the _documentation_
and not the code.
I have no idea whether this is an eTeX, a PDFTeX, an Aleph or a LuaTeX
invention (did I forget anything?), but it certainly can't stay like
that.
Sorry if I sound like a whiner here. If you think it worth the
trouble, I can rework the arithmetic (but there is a reason that Knuth
kept to 15 bit factors, so it is going to become more complicated).
But I consider it more likely that nc should be changed to 1370:107
which is the closest 15 bit fraction to 12nd (it is smaller than 12nd,
but the next larger suitable fraction 32163:2512 is slightly further
from 12nd). Please remember that in TeX, 2in is not equal to 1in+1in
anyway. I think we can afford this.
Certainly better than the current behavior.
--
David Kastrup
_______________________________________________
dev-luatex mailing list
dev-luatex at ntg.nl
http://www.ntg.nl/mailman/listinfo/dev-luatex
More information about the ntg-pdftex
mailing list