Received: from mout.gmx.net (mout.gmx.net [212.227.15.18]) by h1439878.stratoserver.net (8.14.2/8.14.2/Debian-2build1) with ESMTP id s44NBSoO002505 for ; Mon, 5 May 2014 01:11:29 +0200 Received: from relay2.uni-heidelberg.de ([129.206.210.211]) by mx-ha.gmx.net (mxgmx112) with ESMTPS (Nemesis) id 0Lsgj7-1WsBN40IAr-012Hh6 for ; Mon, 05 May 2014 01:11:23 +0200 Received: from listserv.uni-heidelberg.de (listserv.uni-heidelberg.de [129.206.100.94]) by relay2.uni-heidelberg.de (8.13.8/8.13.8) with ESMTP id s44N8mdl028032 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Mon, 5 May 2014 01:08:48 +0200 Received: from listserv.uni-heidelberg.de (listserv.uni-heidelberg.de [127.0.0.1]) by listserv.uni-heidelberg.de (8.13.8/8.13.8) with ESMTP id s44M13M3013656; Mon, 5 May 2014 01:08:47 +0200 Received: by LISTSERV.UNI-HEIDELBERG.DE (LISTSERV-TCP/IP release 16.0) with spool id 10864945 for LATEX-L@LISTSERV.UNI-HEIDELBERG.DE; Mon, 5 May 2014 01:08:47 +0200 Received: from relay.uni-heidelberg.de (relay.uni-heidelberg.de [129.206.100.212]) by listserv.uni-heidelberg.de (8.13.8/8.13.8) with ESMTP id s44N8lNc018402 for ; Mon, 5 May 2014 01:08:47 +0200 Received: from mail-ee0-f45.google.com (mail-ee0-f45.google.com [74.125.83.45]) by relay.uni-heidelberg.de (8.14.1/8.14.1) with ESMTP id s44N8dXc024569 (version=TLSv1/SSLv3 cipher=RC4-SHA bits=128 verify=FAIL) for ; Mon, 5 May 2014 01:08:42 +0200 Received: by mail-ee0-f45.google.com with SMTP id d49so767689eek.18 for ; Sun, 04 May 2014 16:08:39 -0700 (PDT) X-Received: by 10.14.215.9 with SMTP id d9mr27569198eep.64.1399244919620; Sun, 04 May 2014 16:08:39 -0700 (PDT) Received: from mellon.site (p54807359.dip0.t-ipconnect.de. [84.128.115.89]) by mx.google.com with ESMTPSA id p9sm13486106eeg.32.2014.05.04.16.08.38 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sun, 04 May 2014 16:08:39 -0700 (PDT) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.5.0 MIME-Version: 1.0 Content-Type: text/plain; charset=windows-1252 Message-ID: <5366C875.9040709@googlemail.com> Date: Mon, 5 May 2014 01:08:37 +0200 Reply-To: Mailing list for the LaTeX3 project Sender: Mailing list for the LaTeX3 project From: Heiko Oberdiek Subject: \__dim_strip_bp:n To: LATEX-L@LISTSERV.UNI-HEIDELBERG.DE Precedence: list List-Help: , List-Unsubscribe: List-Subscribe: List-Owner: List-Archive: Content-Transfer-Encoding: quoted-printable X-MIME-Autoconverted: from 8bit to quoted-printable by relay2.uni-heidelberg.de id s44N8mdl028032 Envelope-To: X-GMX-Antispam: 0 (Mail was not recognized as spam); Detail=V3; X-GMX-Antivirus: 0 (no virus found) X-UI-Filterresults: notjunk:1;V01:K0:Tk7RTQPAtjE=:l8oZMEJdx7G+mp77vrHXVHz9NS 9K3H7rUNYmYKPKi2AxALC2vMwx+Ze955CPMXsPtM9owF8uZkWY+YtJfxXeHOxJ60Vx8ZjMcNK q+SL2haj1l3eHz0+3bsnip+oULwF2C+wdj3oSP6Im75A4Nixd9uqBFHp7F6egGIjqGhJ8UVrw LFKho7TXM56bqsJm4esYF4dC1092JzCoPB1dgxVhlaOak54AvWOt8/gBKmSGK4h5tBeYiaLl6 582l077Pt0cLpScu326Dep13AJZrzX1w3Z472+LCy2u0y8SZCj80duhQA7nSDeeWvqp1EC/DQ Vz2QVP4Yi3E0VQwVzZkfyagG2AMd8WrG8E2uGvaIgFvH3yn54oxW11sevkw4ThaXGPi5JDTWn i0TPurx1IuRi2ZvbKdmVlu/kOQjt8YdfRg7oYIXa6oRWMnYOUWJM203xGE2iQIbLw0wrlDn1u XXxvgCV+uCmtlGe1As7bh/81itkXuE0aWvF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-UID: 7387 Hello, macro \__dim_strip_bp:n is defined in l3skip.dtx the following way: \cs_new:Npn \__dim_strip_bp:n #1 { \__dim_strip_pt:n { 0.996 26 \__dim_eval:w #1 \__dim_eval_end: } } The calculation from bp to bp is essentially: \dimexpr 0.99626\dimexpr #1\relax\relax Of course, there will always be rounding errors, but the code can be improved by a scaling operation inside e-TeX's \dimexpr, from "The e-TeX manual": | The arithmetic operations are performed individually, except | for =91scaling=92 operations (a multiplication immediately followed | by a division) which are performed as one combined operation | with a 64-bit product as intermediate value. Improved version with higher precision: \cs_new:Npn \__dim_strip_bp:n #1 { \__dim_strip_pt:n { \__dim_eval:w ( #1 ) * 800 / 803 \__dim_eval_end: } } * 800/803 is the integer fraction for 72/72.27 * The parentheses around #1 ensure, that #1 is calculated first. Yours sincerely Heiko Oberdiek