diff options
author | Karl Berry <karl@freefriends.org> | 2021-07-14 21:11:14 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2021-07-14 21:11:14 +0000 |
commit | 77927048ddfb38038b1cd5e4ce779a1181dddbf5 (patch) | |
tree | 4da4c9a23438fe0cadd3e050720fe84735a55625 | |
parent | f44797c65183b9645ea96096a4f8ab92b5c64298 (diff) |
xint (14jul21)
git-svn-id: svn://tug.org/texlive/trunk@59930 c570f23f-e606-0410-a88d-b1316a301751
17 files changed, 359 insertions, 298 deletions
diff --git a/Master/texmf-dist/doc/generic/xint/CHANGES.html b/Master/texmf-dist/doc/generic/xint/CHANGES.html index c8a210a56af..eb355ab053d 100644 --- a/Master/texmf-dist/doc/generic/xint/CHANGES.html +++ b/Master/texmf-dist/doc/generic/xint/CHANGES.html @@ -4,7 +4,7 @@ <meta charset="utf-8" /> <meta name="generator" content="pandoc" /> <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" /> - <meta name="author" content="xint 1.4i" /> + <meta name="author" content="xint 1.4j" /> <title>CHANGE LOG</title> <style type="text/css"> code{white-space: pre-wrap;} @@ -25,73 +25,76 @@ <body> <header> <h1 class="title">CHANGE LOG</h1> -<p class="author">xint 1.4i</p> -<p class="date">2021/06/11</p> +<p class="author">xint 1.4j</p> +<p class="date">2021/07/13</p> </header> <nav id="TOC"> <ul> -<li><a href="#i-20210611"><code>1.4i (2021/06/11)</code></a><ul> +<li><a href="#j-20210713"><code>1.4j (2021/07/13)</code></a><ul> <li><a href="#bug-fixes">Bug fixes</a></li> +</ul></li> +<li><a href="#i-20210611"><code>1.4i (2021/06/11)</code></a><ul> <li><a href="#new-features">New features</a></li> +<li><a href="#bug-fixes-1">Bug fixes</a></li> </ul></li> <li><a href="#h-20210527"><code>1.4h (2021/05/27)</code></a><ul> -<li><a href="#bug-fixes-1">Bug fixes</a></li> +<li><a href="#bug-fixes-2">Bug fixes</a></li> </ul></li> <li><a href="#g-20210525"><code>1.4g (2021/05/25)</code></a><ul> <li><a href="#breaking-changes">Breaking changes</a></li> <li><a href="#deprecated">Deprecated</a></li> -<li><a href="#bug-fixes-2">Bug fixes</a></li> <li><a href="#new-features-1">New features</a></li> +<li><a href="#bug-fixes-3">Bug fixes</a></li> </ul></li> <li><a href="#f-20210510"><code>1.4f (2021/05/10)</code></a><ul> <li><a href="#breaking-changes-1">Breaking changes</a></li> -<li><a href="#bug-fixes-3">Bug fixes</a></li> +<li><a href="#bug-fixes-4">Bug fixes</a></li> </ul></li> <li><a href="#e-20210505"><code>1.4e (2021/05/05)</code></a><ul> <li><a href="#breaking-changes-2">Breaking changes</a></li> <li><a href="#new-features-2">New features</a></li> -<li><a href="#bug-fixes-4">Bug fixes</a></li> +<li><a href="#bug-fixes-5">Bug fixes</a></li> </ul></li> <li><a href="#d-20210329"><code>1.4d (2021/03/29)</code></a><ul> <li><a href="#breaking-changes-3">Breaking changes</a></li> -<li><a href="#bug-fixes-5">Bug fixes</a></li> +<li><a href="#bug-fixes-6">Bug fixes</a></li> </ul></li> <li><a href="#c-20210220"><code>1.4c (2021/02/20)</code></a><ul> -<li><a href="#bug-fixes-6">Bug fixes</a></li> +<li><a href="#bug-fixes-7">Bug fixes</a></li> </ul></li> <li><a href="#b-20200225"><code>1.4b (2020/02/25)</code></a><ul> <li><a href="#future">Future</a></li> <li><a href="#new-features-3">New features</a></li> -<li><a href="#bug-fixes-7">Bug fixes</a></li> +<li><a href="#bug-fixes-8">Bug fixes</a></li> </ul></li> <li><a href="#a-20200219"><code>1.4a (2020/02/19)</code></a><ul> <li><a href="#breaking-changes-4">Breaking changes</a></li> <li><a href="#new-features-4">New features</a></li> -<li><a href="#bug-fixes-8">Bug fixes</a></li> +<li><a href="#bug-fixes-9">Bug fixes</a></li> </ul></li> <li><a href="#section"><code>1.4 (2020/01/31)</code></a><ul> <li><a href="#breaking-changes-5">Breaking changes</a></li> <li><a href="#improvements-and-new-features">Improvements and new features</a></li> -<li><a href="#bug-fixes-9">Bug fixes</a></li> +<li><a href="#bug-fixes-10">Bug fixes</a></li> <li><a href="#todo">TODO</a></li> </ul></li> <li><a href="#f-20190910"><code>1.3f (2019/09/10)</code></a><ul> <li><a href="#improvements-and-new-features-1">Improvements and new features</a></li> -<li><a href="#bug-fixes-10">Bug fixes</a></li> +<li><a href="#bug-fixes-11">Bug fixes</a></li> </ul></li> <li><a href="#e-20190405"><code>1.3e (2019/04/05)</code></a><ul> <li><a href="#breaking-changes-6">Breaking changes</a></li> <li><a href="#improvements-and-new-features-2">Improvements and new features</a></li> -<li><a href="#bug-fixes-11">Bug fixes</a></li> +<li><a href="#bug-fixes-12">Bug fixes</a></li> </ul></li> <li><a href="#d-20190106"><code>1.3d (2019/01/06)</code></a><ul> <li><a href="#breaking-changes-7">Breaking changes</a></li> <li><a href="#improvements-and-new-features-3">Improvements and new features</a></li> -<li><a href="#bug-fixes-12">Bug fixes</a></li> +<li><a href="#bug-fixes-13">Bug fixes</a></li> </ul></li> <li><a href="#c-20180617"><code>1.3c (2018/06/17)</code></a><ul> <li><a href="#improvements-and-new-features-4">Improvements and new features</a></li> -<li><a href="#bug-fixes-13">Bug fixes</a></li> +<li><a href="#bug-fixes-14">Bug fixes</a></li> </ul></li> <li><a href="#b-20180518"><code>1.3b (2018/05/18)</code></a><ul> <li><a href="#improvements-and-new-features-5">Improvements and new features</a></li> @@ -99,7 +102,7 @@ <li><a href="#a-20180307"><code>1.3a (2018/03/07)</code></a><ul> <li><a href="#removed">Removed</a></li> <li><a href="#improvements-and-new-features-6">Improvements and new features</a></li> -<li><a href="#bug-fixes-14">Bug fixes</a></li> +<li><a href="#bug-fixes-15">Bug fixes</a></li> </ul></li> <li><a href="#section-1"><code>1.3 (2018/03/01)</code></a><ul> <li><a href="#breaking-changes-8">Breaking changes</a></li> @@ -107,12 +110,12 @@ </ul></li> <li><a href="#q-20180206"><code>1.2q (2018/02/06)</code></a><ul> <li><a href="#improvements-and-new-features-8">Improvements and new features</a></li> -<li><a href="#bug-fixes-15">Bug fixes</a></li> +<li><a href="#bug-fixes-16">Bug fixes</a></li> </ul></li> <li><a href="#p-20171205"><code>1.2p (2017/12/05)</code></a><ul> <li><a href="#breaking-changes-9">Breaking changes</a></li> <li><a href="#improvements-and-new-features-9">Improvements and new features</a></li> -<li><a href="#bug-fixes-16">Bug fixes</a></li> +<li><a href="#bug-fixes-17">Bug fixes</a></li> </ul></li> <li><a href="#o-20170829"><code>1.2o (2017/08/29)</code></a><ul> <li><a href="#breaking-changes-10">Breaking changes</a></li> @@ -125,31 +128,31 @@ <li><a href="#m-20170731"><code>1.2m (2017/07/31)</code></a><ul> <li><a href="#breaking-changes-12">Breaking changes</a></li> <li><a href="#improvements-and-new-features-11">Improvements and new features</a></li> -<li><a href="#bug-fixes-17">Bug fixes</a></li> +<li><a href="#bug-fixes-18">Bug fixes</a></li> </ul></li> <li><a href="#l-20170726"><code>1.2l (2017/07/26)</code></a><ul> <li><a href="#removed-1">Removed</a></li> <li><a href="#improvements-and-new-features-12">Improvements and new features</a></li> -<li><a href="#bug-fixes-18">Bug fixes</a></li> +<li><a href="#bug-fixes-19">Bug fixes</a></li> </ul></li> <li><a href="#k-20170106"><code>1.2k (2017/01/06)</code></a><ul> <li><a href="#breaking-changes-13">Breaking changes</a></li> <li><a href="#improvements-and-new-features-13">Improvements and new features</a></li> -<li><a href="#bug-fixes-19">Bug fixes</a></li> +<li><a href="#bug-fixes-20">Bug fixes</a></li> </ul></li> <li><a href="#j-20161222"><code>1.2j (2016/12/22)</code></a><ul> <li><a href="#improvements-and-new-features-14">Improvements and new features</a></li> -<li><a href="#bug-fixes-20">Bug fixes</a></li> +<li><a href="#bug-fixes-21">Bug fixes</a></li> </ul></li> <li><a href="#i-20161213"><code>1.2i (2016/12/13)</code></a><ul> <li><a href="#breaking-changes-14">Breaking changes</a></li> <li><a href="#removed-2">Removed</a></li> <li><a href="#improvements-and-new-features-15">Improvements and new features</a></li> -<li><a href="#bug-fixes-21">Bug fixes</a></li> +<li><a href="#bug-fixes-22">Bug fixes</a></li> </ul></li> <li><a href="#h-20161120"><code>1.2h (2016/11/20)</code></a><ul> <li><a href="#improvements-and-new-features-16">Improvements and new features</a></li> -<li><a href="#bug-fixes-22">Bug fixes</a></li> +<li><a href="#bug-fixes-23">Bug fixes</a></li> </ul></li> <li><a href="#g-20160319"><code>1.2g (2016/03/19)</code></a><ul> <li><a href="#breaking-changes-15">Breaking changes</a></li> @@ -158,26 +161,26 @@ <li><a href="#f-20160312"><code>1.2f (2016/03/12)</code></a><ul> <li><a href="#breaking-changes-16">Breaking changes</a></li> <li><a href="#improvements-and-new-features-18">Improvements and new features</a></li> -<li><a href="#bug-fixes-23">Bug fixes</a></li> +<li><a href="#bug-fixes-24">Bug fixes</a></li> </ul></li> <li><a href="#e-20151122"><code>1.2e (2015/11/22)</code></a><ul> <li><a href="#improvements-and-new-features-19">Improvements and new features</a></li> -<li><a href="#bug-fixes-24">Bug fixes</a></li> +<li><a href="#bug-fixes-25">Bug fixes</a></li> </ul></li> <li><a href="#d-20151118"><code>1.2d (2015/11/18)</code></a><ul> <li><a href="#improvements-and-new-features-20">Improvements and new features</a></li> -<li><a href="#bug-fixes-25">Bug fixes</a></li> +<li><a href="#bug-fixes-26">Bug fixes</a></li> </ul></li> <li><a href="#c-20151116"><code>1.2c (2015/11/16)</code></a><ul> <li><a href="#improvements-and-new-features-21">Improvements and new features</a></li> -<li><a href="#bug-fixes-26">Bug fixes</a></li> +<li><a href="#bug-fixes-27">Bug fixes</a></li> </ul></li> <li><a href="#b-20151029"><code>1.2b (2015/10/29)</code></a><ul> -<li><a href="#bug-fixes-27">Bug fixes</a></li> +<li><a href="#bug-fixes-28">Bug fixes</a></li> </ul></li> <li><a href="#a-20151019"><code>1.2a (2015/10/19)</code></a><ul> <li><a href="#improvements-and-new-features-22">Improvements and new features</a></li> -<li><a href="#bug-fixes-28">Bug fixes</a></li> +<li><a href="#bug-fixes-29">Bug fixes</a></li> </ul></li> <li><a href="#section-2"><code>1.2 (2015/10/10)</code></a><ul> <li><a href="#removed-3">Removed</a></li> @@ -191,7 +194,7 @@ <li><a href="#removed-4">Removed</a></li> <li><a href="#deprecated-2">Deprecated</a></li> <li><a href="#improvements-and-new-features-24">Improvements and new features</a></li> -<li><a href="#bug-fixes-29">Bug fixes</a></li> +<li><a href="#bug-fixes-30">Bug fixes</a></li> </ul></li> <li><a href="#n-20140401"><code>1.09n (2014/04/01)</code></a></li> <li><a href="#m-20140226"><code>1.09m (2014/02/26)</code></a></li> @@ -219,24 +222,29 @@ <li><a href="#section-10"><code>1.0 (2013/03/28)</code></a></li> </ul> </nav> -<pre><code>Source: xint.dtx 1.4i 2021/06/11 (doc 2021/06/11) +<pre><code>Source: xint.dtx 1.4j 2021/07/13 (doc 2021/07/13) Author: Jean-Francois Burnol Info: Expandable operations on big integers, decimals, fractions License: LPPL 1.3c</code></pre> -<h2 id="i-20210611"><code>1.4i (2021/06/11)</code></h2> +<h2 id="j-20210713"><code>1.4j (2021/07/13)</code></h2> <h3 id="bug-fixes">Bug fixes</h3> <ul> -<li><p><strong>xintexpr</strong>: simultaneous assignments via <code>\xintdefvar</code> to 10 or more variables was broken if the right hand side was an ople (of length at least 10, as it had prior to this release to match the number of variables).</p></li> -<li><p><strong>xintexpr</strong>: the mechanism which allows to define variables with names already in use for pre-existing functions was broken for some built-in functions: those handling syntax with dummy variables (currently <code>subs()</code>, <code>subsm()</code>, <code>subsn()</code>, <code>seq()</code>, <code>add()</code>, <code>mul()</code>, <code>ndseq()</code>, <code>ndmap()</code>, <code>ndfillraw()</code>) and the so-called “pseudo” functions (currently <code>bool()</code>, <code>togl()</code>, <code>protect()</code>, <code>qint()</code>, <code>qfrac()</code>, <code>qfloat()</code>, <code>qraw()</code>, <code>random()</code>, <code>qrand()</code>, <code>rbit()</code>). For example the function <code>seq()</code> was broken if the user had defined a variable <code>seq</code>.</p></li> +<li><strong>xinttools</strong>: a brace removal bug affected the venerable <code>\xintSeq</code> if producing a single number (e.g. <code>\xintSeq{10}{10}</code> expanded to <code>10</code> not <code>{10}</code>). Thanks to Christophe Poulain for report.</li> </ul> +<h2 id="i-20210611"><code>1.4i (2021/06/11)</code></h2> <h3 id="new-features">New features</h3> <ul> <li><p><strong>xintexpr</strong>: the concept of simultaneous assignments is extended: in case of more variables than values the extraneous variables do not cause an error message but are simply set to the <code>nil</code> value; in case of more values than variables, the last variable is defined to be the ople concatenating all the extra values.</p></li> <li><p><strong>xintexpr</strong>: built-in functions usable with arbitrarily many arguments such as <code>max()</code>, <code>gcd()</code>, or <code>len()</code> are now again usable with a single numeric argument: since <code>1.4</code> a lone argument had to be a <code>nutple</code> (which was automatically unpacked). It can now again be a number.</p></li> </ul> -<h2 id="h-20210527"><code>1.4h (2021/05/27)</code></h2> <h3 id="bug-fixes-1">Bug fixes</h3> <ul> +<li><p><strong>xintexpr</strong>: simultaneous assignments via <code>\xintdefvar</code> to 10 or more variables was broken if the right hand side was an ople (of length at least 10, as it had prior to this release to match the number of variables).</p></li> +<li><p><strong>xintexpr</strong>: the mechanism which allows to define variables with names already in use for pre-existing functions was broken for some built-in functions: those handling syntax with dummy variables (currently <code>subs()</code>, <code>subsm()</code>, <code>subsn()</code>, <code>seq()</code>, <code>add()</code>, <code>mul()</code>, <code>ndseq()</code>, <code>ndmap()</code>, <code>ndfillraw()</code>) and the so-called “pseudo” functions (currently <code>bool()</code>, <code>togl()</code>, <code>protect()</code>, <code>qint()</code>, <code>qfrac()</code>, <code>qfloat()</code>, <code>qraw()</code>, <code>random()</code>, <code>qrand()</code>, <code>rbit()</code>). For example the function <code>seq()</code> was broken if the user had defined a variable <code>seq</code>.</p></li> +</ul> +<h2 id="h-20210527"><code>1.4h (2021/05/27)</code></h2> +<h3 id="bug-fixes-2">Bug fixes</h3> +<ul> <li><p><strong>xintexpr</strong>: the recent <code>1.4g</code> introduced a bug breaking input of the type <code><operator><space token><macro></code>.</p></li> <li><p><strong>xintexpr</strong>: since <code>1.4</code> (<code>2020/01/31</code>) the <code>omit</code> and <code>abort</code> keywords were broken if used inside a substitution, itself nested in a <code>seq()</code> or similar construct.</p></li> <li><p><strong>xintexpr</strong>: since <code>1.4c</code> the <code>\xintthespaceseparated</code> (added at <code>1.4a</code>) inserted two, not one, spaces at one specific location near the end of its output. A bit cosmetic problem, fixed nevertheless.</p></li> @@ -251,7 +259,12 @@ License: LPPL 1.3c</code></pre> <ul> <li><strong>xintfrac</strong>: old typesetting macros dating back to <code>1.03</code> and <code>1.04</code> releases <code>\xintFrac</code>, <code>\xintSignedFrac</code>, <code>\xintFwOver</code>, <code>\xintSignedFwOver</code> are deprecated. Please use the new names <code>\xintTeXFrac</code>, <code>\xintTeXsignedFrac</code>, <code>\xintTeXOver</code>, <code>\xintTeXsignedOver</code>. The old names will emit warnings.</li> </ul> -<h3 id="bug-fixes-2">Bug fixes</h3> +<h3 id="new-features-1">New features</h3> +<ul> +<li><p>Messages written to the terminal and log file during the handling of recovery from exceptions use a new mechanism; when in interactive mode, the user is prompted only once, not thrice, to enter <code><return></code> for recovery and continued processing.</p></li> +<li><p><strong>xintfrac</strong>: <code>\xintTeXfromSci</code> (added about 7 or 8 years too late) to help typesetting values output by <code>\xintfloateval</code> in a more useful way than <code>\xintTeXFrac</code> (formerly <code>\xintFrac</code>).</p></li> +</ul> +<h3 id="bug-fixes-3">Bug fixes</h3> <ul> <li><p><strong>xintexpr</strong>: with <strong>xintbinhex</strong> loaded, <code>"</code> is recognized as prefix for hexadecimal input; but a bug (present ever since this support for hexadecimal input was added) caused syntax such as <code>"\macro</code> to break the parser. Also, leading zeros such as in <code>"0000A</code> where not properly trimmed since <code>1.2m</code>.</p></li> <li><p><strong>xintexpr</strong>: authorize <code>x! == y</code> without parentheses. Formerly the parser mis-interpreted <code>!</code> as first character of the <code>!=</code> not-equal-to comparison operator, subsequently causing breakage when finding the second <code>=</code>.</p></li> @@ -266,11 +279,6 @@ License: LPPL 1.3c</code></pre> </ul> <p>Surely, further situations remain where bad input will crash parser.</p></li> </ul> -<h3 id="new-features-1">New features</h3> -<ul> -<li><p>Messages written to the terminal and log file during the handling of recovery from exceptions use a new mechanism; when in interactive mode, the user is prompted only once, not thrice, to enter <code><return></code> for recovery and continued processing.</p></li> -<li><p><strong>xintfrac</strong>: <code>\xintTeXfromSci</code> (added about 7 or 8 years too late) to help typesetting values output by <code>\xintfloateval</code> in a more useful way than <code>\xintTeXFrac</code> (formerly <code>\xintFrac</code>).</p></li> -</ul> <h2 id="f-20210510"><code>1.4f (2021/05/10)</code></h2> <h3 id="breaking-changes-1">Breaking changes</h3> <ul> @@ -280,7 +288,7 @@ License: LPPL 1.3c</code></pre> <li><p><strong>xintexpr</strong>: further changes in the computation of powers, see the bug fixes below.</p></li> <li><p><strong>xintexpr</strong>: the <code>float_()</code> function got renamed into <code>float_dgt()</code>.</p></li> </ul> -<h3 id="bug-fixes-3">Bug fixes</h3> +<h3 id="bug-fixes-4">Bug fixes</h3> <ul> <li><p><strong>xintexpr</strong>: the documentation said <code>float_()</code> function had been renamed <code>float_dgt()</code> but actually that was not yet the case.</p></li> <li><p><strong>xintexpr</strong>: powers <code>a^b</code> (with exponent <code>b</code> neither integer nor half-integer) stopped being accurate regarding the last digits for <code>|b|</code> about <code>1000</code> and beyond. Except for <code>0.8<a<1.25</code> for which accuracy was maintained up to about <code>|b|=10^7</code>. Fixed via keeping the same suitable number of extra digits for internal computations of logarithms, independently of whether <code>a</code> is close to <code>1</code> or not.</p></li> @@ -309,7 +317,7 @@ License: LPPL 1.3c</code></pre> <li><p><strong>xintfrac</strong>: <code>\xintPFloatE</code> may be redefined as a macro which fetches the scientific exponent as a mandatory argument delimited with a dot, and outputs a suitable formatted result (f-expandably), also delimited with a dot which will be removed by internal processing. The default however simply expands to the letter <code>e</code>.</p></li> <li><p><strong>xintfrac</strong>: <code>\xintDecToStringREZ</code> is like <code>\xintDecToString</code> but starts by removing trailing zeroes.</p></li> </ul> -<h3 id="bug-fixes-4">Bug fixes</h3> +<h3 id="bug-fixes-5">Bug fixes</h3> <ul> <li><strong>xintfrac</strong>, <strong>xintexpr</strong>: it was not possible to use <code>\xinttheDigits</code> in the right hand side of an <code>\xintDigits</code> assignment. For example: <code>\xintDigits*:=\numexpr\xinttheDigits+4;</code>. This is now allowed, and the same applies to the macro interface, for example <code>\xintSetDigits*{\xinttheDigits+4}</code>.</li> </ul> @@ -320,7 +328,7 @@ License: LPPL 1.3c</code></pre> <li><p>The output of <code>gcd()</code> and <code>lcm()</code> as applied to fractions is now always in lowest terms.</p></li> <li><p>The log message to report a variable creation (if <code>\xintverbosetrue</code>) does not use (double) quotes anymore around the name. By the way, quotes were never used for function names.</p></li> </ul> -<h3 id="bug-fixes-5">Bug fixes</h3> +<h3 id="bug-fixes-6">Bug fixes</h3> <ul> <li><p>Ever since <code>1.3</code> the <code>quo()</code> and <code>rem()</code> functions in <code>\xintexpr</code> (not the ones in <code>\xintiiexpr</code>) were broken as their (officially deprecated) support macros had been removed! They had somewhat useless definitions anyway. They have now been officially removed from the syntax. Their siblings in <code>\xintiieval</code> were renamed to <code>iquo()</code> and <code>irem()</code>.</p></li> <li><p>Sadly, <code>gcd()</code> was broken in <code>\xintexpr</code> since <code>1.4</code>, if the first argument vanished. And <code>gcd()</code> was broken in <code>\xintiiexpr</code> since <code>1.3d</code> if <em>any</em> argument vanished. I did have a unit test! (which obviously was too limited …)</p> @@ -328,7 +336,7 @@ License: LPPL 1.3c</code></pre> <li><p>The <code>first()</code> and <code>last()</code> functions, if used as arguments to numerical functions such as <code>sqr()</code> inside an <code>\xintdeffunc</code> caused the defined function to be broken.</p></li> </ul> <h2 id="c-20210220"><code>1.4c (2021/02/20)</code></h2> -<h3 id="bug-fixes-6">Bug fixes</h3> +<h3 id="bug-fixes-7">Bug fixes</h3> <ul> <li>Fix <code>1.4</code> regression which broke syntax <code>varname(...)</code> which supposedly is allowed and inserts a tacit multiplication.</li> </ul> @@ -347,7 +355,7 @@ License: LPPL 1.3c</code></pre> <li><p>Chaining of comparison operators (e.g. <code>x<y<z</code>) as in Python (but all comparisons are done even if one is found false) and l3fp.</p></li> <li><p>It was possible since <code>1.4</code>’s <code>\xintFracToSciE</code> to configure the separator between mantissas and exponents in the output of <code>\xinteval</code> but strangely there was no way to customize the output of <code>\xintfloateval</code>. The added <code>\xintPFloatE</code> fixes this.</p></li> </ul> -<h3 id="bug-fixes-7">Bug fixes</h3> +<h3 id="bug-fixes-8">Bug fixes</h3> <ul> <li><code>\xintieval{[D]...}</code> with a negative <code>D</code> (a feature added at <code>1.4a</code>) used erroneously a catcode 12 <code>e</code> in output, which moreover remained immuned to the <code>\xintFracToSciE</code> setting.</li> </ul> @@ -363,7 +371,7 @@ License: LPPL 1.3c</code></pre> <li><p>The optional argument <code>[D]</code> to <code>\xintieval/\xintiexpr</code> can be negative, with the same meaning as the non-negative case, i.e. rounding to an integer multiple of <code>10^(-D)</code>.</p> <p>The same applies to the functions <code>trunc()</code> and <code>round()</code>. And to the <code>\xintTrunc</code>, <code>\xintRound</code>, <code>\xintiTrunc</code>, and <code>\xintiRound</code> macros of <strong>xintfrac</strong>.</p></li> </ul> -<h3 id="bug-fixes-8">Bug fixes</h3> +<h3 id="bug-fixes-9">Bug fixes</h3> <ul> <li><p>Usage of <code>round()</code> and <code>trunc()</code> within <code>\xintdeffunc</code> got broken at <code>1.4</code>.</p></li> <li><p><code>add()</code> and <code>mul()</code> were supposedly accepting the <code>omit</code>, <code>abort</code> and <code>break()</code> keywords since <code>1.4</code> but this was broken.</p></li> @@ -393,7 +401,7 @@ License: LPPL 1.3c</code></pre> <li><p>The <code>*</code> serves as <em>unpacking</em> operator on <em>nut-ples</em>, i.e. reversing the <code>[]</code> bracketing of an <em>ople</em>.</p></li> <li><p><em>oples</em> have no exact equivalent in <code>Python</code>. For example <strong>xintexpr</strong> allows <code>foo(Var1, x)</code> if <code>foo</code> is a function of 4 variables and <code>Var1</code> is a variable producing a length 3 <em>ople</em>, or <code>foo(Var2)</code> if <code>Var2</code> is a variable producing a length 4 <em>ople</em>. Python would require here to use explicitly the <code>*</code>-unpacking notation on some “packed” objects.</p> <p>Variable and function values may be <em>oples</em> (even <em>nil</em>), but in function declarations variables must stand for <em>one-ples</em>, i.e. either <em>numbers</em> or <em>nut-ples</em> (as there is no non-ambiguous way to split e.g. 5 arguments into two separate <em>oples</em>).</p></li> -<li><p>Simultaneous assignment to at least two variables via <code>\xintdefvar</code> et al. automatically unpacks the assigned value if it is a <em>one-ple</em>. If this value was in fact a <em>number</em>, low-level errors will result shortly afterwards as no check is done if the unpacking was illicit. (Such checks exist in the codebase, but have not yet been integrated into <code>\xintdefvar</code> by laziness).</p></li> +<li><p>Simultaneous assignment to at least two variables via <code>\xintdefvar</code> et al. automatically unpacks the assigned value if it is a <em>one-ple</em>. If this value was in fact a <em>number</em>, low-level errors will result shortly afterwards as no check is done if the unpacking was illicit. (update: this last remark does not apply since the <code>1.4i</code> extension to the concept of simultaneous assignments)</p></li> <li><p>The <code>NumPy</code> concept and syntax for nested slicing and item selection are implemented. Currently <em>stepping</em> and the <em>Ellipsis object</em> are not yet available. Only so-called basic slicing is currently supported. (The author has not yet read the section of <code>NumPy</code> documentation on so-called <em>advanced indexing</em>).</p></li> <li><p>The <em>broadcasting</em> of scalar operations, such as itemwise addition or multiplication of <em>nut-ples</em> of the same shape is <strong>not yet implemented</strong>.</p></li> <li><p>Slicing and indexing apply also at top level to the <em>oples</em> with behaviour conforming to intuitive expectations (see user manual); if it turns out the <em>ople</em> is in fact a <em>nut-ple</em>, the top-level slicing/indexing switches to the <code>Python/NumPy</code> conventions, i.e. it operates inside the brackets for slicing and removes brackets if indexing.</p></li> @@ -415,7 +423,7 @@ License: LPPL 1.3c</code></pre> <li><p>Function declarations are able to parse a much wider part of the syntax, but some severe limitations remain. Refer to the user manual for related information.</p></li> <li><p>We have made an effort on some error messages, and when working interactively in a shell it may even be sometimes possible to insert for example a correct variable or function name in place of the not recognized one. But don’t expect miracles when trying to intervene in the midst of a purely expandable expansion…</p></li> </ul> -<h3 id="bug-fixes-9">Bug fixes</h3> +<h3 id="bug-fixes-10">Bug fixes</h3> <p>Bugs? Those identified in <code>1.3f</code> were almost features. As per <code>1.4</code> the code base of <strong>xintexpr</strong> received multiple successive core refactorings and added numerous new features, and our test suite although significantly enlarged is not yet extensive enough. Please report bugs by mail.</p> <h3 id="todo">TODO</h3> <ul> @@ -431,7 +439,7 @@ License: LPPL 1.3c</code></pre> <li><p><strong>xintexpr</strong>: add starred variants <code>\xintDigits*</code> and <code>\xintSetDigits*</code> which execute <code>\xintreloadxinttrig</code>.</p> <p>Revert 1.3e ban on usage of <code>\xinteval</code> et al. inside expressions by <code>\xintdeffunc</code>. And make them usable also inside macro definitions via <code>\xintNewExpr</code>.</p></li> </ul> -<h3 id="bug-fixes-10">Bug fixes</h3> +<h3 id="bug-fixes-11">Bug fixes</h3> <ul> <li><p><strong>xintexpr</strong>: fix bug preventing usage of <code>\xintdefefunc</code> to define a function without variables.</p> <p>Fix some issue with <code>\xintfloatexpr[D]..\relax</code> if used inside an expression parsed by <code>\xintdeffunc</code> et al.</p></li> @@ -451,7 +459,7 @@ License: LPPL 1.3c</code></pre> <li><p><strong>xintexpr</strong>: <code>\xintensuredummy</code>, <code>\xintrestorelettervar</code>.</p></li> <li><p>The optional argument of <code>\xintfloatexpr</code> or <code>\xintfloateval</code> (it must be at start of braced argument) can be negative; it then means to trim (and round) from the output at float precision that many least significant digits.</p></li> </ul> -<h3 id="bug-fixes-11">Bug fixes</h3> +<h3 id="bug-fixes-12">Bug fixes</h3> <ul> <li>Some bugfixes related to user functions with no variables at all; they were dysfunctional.</li> </ul> @@ -470,7 +478,7 @@ License: LPPL 1.3c</code></pre> <li><p><strong>xintexpr</strong>: functions <code>isone()</code> and <code>isint()</code>.</p></li> <li><p><strong>xintexpr</strong>: <code>\xinteval</code>, <code>\xintieval</code>, <code>\xintiieval</code>, and <code>\xintfloateval</code> as synonyms to <code>\xinttheexpr...\relax</code> etc…, but with the (comma-separated) expression as a usual braced macro argument.</p></li> </ul> -<h3 id="bug-fixes-12">Bug fixes</h3> +<h3 id="bug-fixes-13">Bug fixes</h3> <ul> <li><strong>xintcore</strong>, <strong>xintexpr</strong> : division in <code>\xintiiexpr</code> was broken for a zero dividend and a one-digit divisor (e.g. <code>0//7</code>) since <code>1.2p</code> due to a bug in <code>\xintiiDivMod</code> for such arguments. The bug was signaled (thanks to Kpym for report) and fixed shortly after <code>1.3c</code> release but I then completely forgot to upload a bugfix release to CTAN at that time, apologies for that.</li> </ul> @@ -483,7 +491,7 @@ License: LPPL 1.3c</code></pre> <li><p><strong>xintexpr</strong>: <code>\xintdefvar</code>, <code>\xintdeffunc</code> and their variants try to set the catcode of the semi-colon which delimits their arguments; of course this will not work if that catcode is already frozen.</p></li> <li><p><code>\xintUniformDeviate</code> is better documented and <code>sourcexint.pdf</code> is better hyperlinked and includes indices for the macros defined by each package.</p></li> </ul> -<h3 id="bug-fixes-13">Bug fixes</h3> +<h3 id="bug-fixes-14">Bug fixes</h3> <ul> <li><strong>xintfrac</strong>: since <code>1.3</code> release, it loaded <strong>xintgcd</strong> in contradiction to what the documentation says (hence also <strong>xintexpr</strong> loaded <strong>xintgcd</strong> automatically). There is no actual dependency so the loading is removed for now.</li> </ul> @@ -509,7 +517,7 @@ License: LPPL 1.3c</code></pre> <li><p><strong>xintfrac</strong>: <code>\xintREZ</code> is faster on inputs having one hundred digits or more.</p></li> <li><p>Added to the user manual mention of macros such as <code>\xintDivFloor</code>, <code>\xintMod</code>, <code>\xintModTrunc</code>, which had been left out so far.</p></li> </ul> -<h3 id="bug-fixes-14">Bug fixes</h3> +<h3 id="bug-fixes-15">Bug fixes</h3> <ul> <li><strong>xintexpr</strong>: the mechanism for adjunction to the expression parsers of user defined functions was refactored and improved at previous release <code>1.3</code>: in particular recursive definitions became possible. But an oversight made these recursive functions quite inefficient (to remain polite.) This release fixes the problem.</li> </ul> @@ -532,7 +540,7 @@ License: LPPL 1.3c</code></pre> <ul> <li><strong>xintexpr</strong>: tacit multiplication extended to cases such as <code>3!4!5!</code> or <code>(1+2)3</code>.</li> </ul> -<h3 id="bug-fixes-15">Bug fixes</h3> +<h3 id="bug-fixes-16">Bug fixes</h3> <ul> <li><strong>xintcore</strong>: sadly, refactoring at <code>1.2l</code> of subtraction left an extra character in an inner macro causing breakage in some rare circumstances. This should not have escaped our test suite!</li> </ul> @@ -551,7 +559,7 @@ License: LPPL 1.3c</code></pre> <li><p><strong>xintexpr</strong>: <code>\xintdefvar</code>’s syntax is extended to allow simultaneous assignments. Examples: <code>\xintdefvar x1, x2, x3 := 1, 3**10, 3**20;</code> or <code>\xintdefiivar A, B := B, A 'mod' B;</code> for already defined variables <code>A</code> and <code>B</code>.</p></li> <li><p><strong>xintexpr</strong>: added <code>divmod()</code> to the built-in functions. It is associated with floored division, like the Python language <code>divmod()</code>. Related support macros added to <strong>xintcore</strong>, and <strong>xintfrac</strong>.</p></li> </ul> -<h3 id="bug-fixes-16">Bug fixes</h3> +<h3 id="bug-fixes-17">Bug fixes</h3> <ul> <li><p><strong>xintgcd</strong>: <code>\xintBezout{6}{3}</code> (for example) expanded to <code>{6}{3}{-0}{-1}{3}</code>, but the <code>-0</code> should have been <code>0</code>.</p></li> <li><p><strong>xintgcd</strong>: it still used macro <code>\xintiAbs</code> although the latter had been deprecated from <strong>xintcore</strong>.</p></li> @@ -594,7 +602,7 @@ License: LPPL 1.3c</code></pre> <ul> <li><strong>xintbinhex</strong>: all macros have been rewritten using techniques from the 1.2 release (they had remained unmodified since <code>1.08</code> of <code>2013/06/07</code>.) The new macros are faster but limited to a few thousand digits. The <code>1.08</code> routines could handle tens of thousands of digits, but not in a reasonable time.</li> </ul> -<h3 id="bug-fixes-17">Bug fixes</h3> +<h3 id="bug-fixes-18">Bug fixes</h3> <ul> <li><p>user manual: the <code>Changes</code> section wrongly stated at <code>1.2l</code> that the macros of <strong>xintbinhex</strong> had been made robust against non terminated input such as <code>\number\mathcode`\-</code>. Unfortunately the author fell into the trap of believing his own documentation and he forgot to actually implement the change. Now done.</p></li> <li><p>user manual: the PDF bookmarks were messed up.</p></li> @@ -615,7 +623,7 @@ License: LPPL 1.3c</code></pre> <p>The situation with expressions is unchanged: syntax such as <code>\xintexpr \numexpr1+2\relax</code> is illegal as the ending <code>\relax</code> token will get swallowed by the <code>\numexpr</code>; but it is needed by the <code>xintexpr</code>-ession parser, hence the parser will expand forward and presumably end with in an “illegal token” error, or provoke some low-level TeX error (N.B.: a closing brace <code>}</code> for example can not terminate an <code>xintexpr</code>-ession, the parser must find a <code>\relax</code> token at some point). Thus there must be in this example a second <code>\relax</code>.</p></li> <li><p>experimental code for error conditions; there is no complete user interface yet, it is done in preparation for next major release and is completely unstable and undocumented.</p></li> </ul> -<h3 id="bug-fixes-18">Bug fixes</h3> +<h3 id="bug-fixes-19">Bug fixes</h3> <ul> <li><p><strong>xintbinhex</strong>: since <code>1.2 (2015/10/10)</code>, <code>\xintHexToDec</code> was broken due to an undefined macro (it was in <code>xint.sty</code>, but the module by itself is supposedly dependent only upon <code>xintcore.sty</code>).</p></li> <li><p><strong>xintgcd</strong>: macro <code>\xintBezout</code> produced partially wrong output if one of its two arguments was zero.</p></li> @@ -634,7 +642,7 @@ License: LPPL 1.3c</code></pre> <li><p>added <code>\xintiSqrtR</code>, there was only <code>\xintiiSqrtR</code> alongside <code>\xintiSqrt</code> and <code>\xintiiSqrt</code> (<strong>xint</strong>).</p></li> <li><p>added non public <code>\xintLastItem:f:csv</code> to <strong>xinttools</strong> for faster <code>last()</code> function, and improved <code>\xintNewExpr</code> compatibility. Also <code>\xintFirstItem:f:csv</code>.</p></li> </ul> -<h3 id="bug-fixes-19">Bug fixes</h3> +<h3 id="bug-fixes-20">Bug fixes</h3> <ul> <li><p>the <code>1.2f</code> half-integer powers computed within <code>\xintfloatexpr</code> had a silly rounding to the target precision just <em>before</em> the final square-root extraction, thus possibly losing some precision. The <code>1.2k</code> implementation keeps guard digits for this final square root extraction. As for integer exponents, it is guaranteed that the computed value differs from the exact one by less than <code>0.52 ulp</code> (for inputs having at most <code>\xinttheDigits</code> digits.)</p></li> <li><p>more regressions from <code>1.2i</code> were fixed: <code>\xintLen</code> (<strong>xint</strong>, <strong>xintfrac</strong>) and <code>\xintDouble</code> (<strong>xintcore</strong>) had forgotten that their argument was allowed to be negative. A regression test suite is now in place and is being slowly expanded to cover more macros.</p></li> @@ -650,7 +658,7 @@ License: LPPL 1.3c</code></pre> </ol></li> <li><p>significant documentations tweaks (inclusive of suppressing things!), and among them two beautiful hyperlinked tables with both horizontal and vertical rules which bring the documentation of the <strong>xintexpr</strong> syntax to a kind of awe-inspiring perfection… except that implementation of some math functions is still lacking.</p></li> </ul> -<h3 id="bug-fixes-20">Bug fixes</h3> +<h3 id="bug-fixes-21">Bug fixes</h3> <ul> <li>fix two <code>1.2i</code> regressions caused by undefined macros (<code>\xintNthElt</code> in certain branches and <code>[list][N]</code> item extraction in certain cases.) The test files existed but were not executed prior to release. Automation in progress.</li> </ul> @@ -682,7 +690,7 @@ License: LPPL 1.3c</code></pre> <li><p>the documentation has again been (slightly) re-organized; it has a new sub-section on the Miller-Rabin primality test, to illustrate some use of <code>\xintNewFunction</code> for recursive definitions.</p></li> <li><p>the documentation has dropped the LaTeX “command” terminology (which had been used initially in 2013 for some forgotten reasons and should have been removed long ago) and uses only the more apt “macro”, as after all, all of <strong>xint</strong> is about expansion of macros (plus the use of <code>\numexpr</code>).</p></li> </ul> -<h3 id="bug-fixes-21">Bug fixes</h3> +<h3 id="bug-fixes-22">Bug fixes</h3> <ul> <li><code>\xintDecSplitL</code> and <code>\xintDecSplitR</code> from <strong>xint</strong> produced their output in a spurious brace pair (bug introduced in <code>1.2f</code>).</li> </ul> @@ -692,7 +700,7 @@ License: LPPL 1.3c</code></pre> <li><p>new macro <code>\xintNewFunction</code> in <strong>xintexpr</strong> which allows to extend the parser syntax with functions in situations where <code>\xintdeffunc</code> is not usable (typically, because dummy variables are used over a not yet determined range of values because it depends on the variables).</p></li> <li><p>after three years of strict obedience to <code>xint</code> prefix, now <code>\thexintexpr</code>, <code>\thexintiexpr</code>, <code>\thexintfloatexpr</code>, and <code>\thexintiiexpr</code> are provided as synonyms to <code>\xinttheexpr</code>, etc…</p></li> </ul> -<h3 id="bug-fixes-22">Bug fixes</h3> +<h3 id="bug-fixes-23">Bug fixes</h3> <ul> <li><p>the <code>(cond)?{foo}{bar}</code> operator from <strong>xintexpr</strong> mis-behaved in certain circumstances (such as an empty <code>foo</code>).</p></li> <li><p>the <strong>xintexpr</strong> <code>1.2f</code> <code>binomial</code> function (which uses <code>\xintiiBinomial</code> from <strong>xint.sty</strong> or <code>\xintFloatBinomial</code> from <strong>xintfrac.sty</strong>) deliberately raised an error for <code>binomial(x,y)</code> with <code>y<0</code> or <code>x<y</code>. This was unfortunate, and it now simply evaluates to zero in such cases.</p></li> @@ -732,7 +740,7 @@ License: LPPL 1.3c</code></pre> <li><p>(TeXperts only) the macros defined (internally) from <code>\xintdeffunc</code> et al. constructs do not incorporate an initial <code>\romannumeral</code> anymore.</p></li> <li><p>renewed desperate efforts at improving the documentation by random shuffling of sections and well thought additions; cuts were considered and even performed.</p></li> </ul> -<h3 id="bug-fixes-23">Bug fixes</h3> +<h3 id="bug-fixes-24">Bug fixes</h3> <ul> <li><p>squaring macro <code>\xintSqr</code> from <strong>xintfrac.sty</strong> was broken due to a misspelled sub-macro name. Dates back to <code>1.1</code> release of <code>2014/10/28</code> <code>:-((</code>.</p></li> <li><p><code>1.2c</code>’s fix to the subtraction bug from <code>1.2</code> introduced another bug, which in some cases could create leading zeroes in the output, or even worse. This could invalidate other routines using subtractions, like <code>\xintiiSquareRoot</code>.</p></li> @@ -746,7 +754,7 @@ License: LPPL 1.3c</code></pre> <li><p>a space in <code>\xintdeffunc f(x)<space>:= expression ;</code> is now accepted.</p></li> <li><p>documentation enhancements: the <em>Quick Sort</em> section with its included code samples has been entirely re-written; the <em>Commands of the xintexpr package</em> section has been extended and reviewed entirely.</p></li> </ul> -<h3 id="bug-fixes-24">Bug fixes</h3> +<h3 id="bug-fixes-25">Bug fixes</h3> <ul> <li><p>in <strong>xintfrac</strong>: the <code>\xintFloatFac</code> from release <code>1.2</code> parsed its argument only through <code>\numexpr</code> but it should have used <code>\xintNum</code>.</p></li> <li><p>in <strong>xintexpr</strong>: release <code>1.2d</code> had broken the recognition of sub-expressions immediately after variable names (with tacit multiplication).</p></li> @@ -759,7 +767,7 @@ License: LPPL 1.3c</code></pre> <li><p>tacit multiplication applies to more cases, for example (x+y)z, and always ties more than standard * infix operator, e.g. x/2y is like x/(2*y).</p></li> <li><p>some documentation enhancements, particularly in the chapter on xintexpr.sty, and also in the code source comments.</p></li> </ul> -<h3 id="bug-fixes-25">Bug fixes</h3> +<h3 id="bug-fixes-26">Bug fixes</h3> <ul> <li>in <strong>xintcore</strong>: release <code>1.2c</code> had inadvertently broken the <code>\xintiiDivRound</code> macro.</li> </ul> @@ -769,12 +777,12 @@ License: LPPL 1.3c</code></pre> <li><p>macros <code>\xintdeffunc</code>, <code>\xintdefiifunc</code>, <code>\xintdeffloatfunc</code> and boolean <code>\ifxintverbose</code>.</p></li> <li><p>on-going code improvements and documentation enhancements, but stopped in order to issue this bugfix release.</p></li> </ul> -<h3 id="bug-fixes-26">Bug fixes</h3> +<h3 id="bug-fixes-27">Bug fixes</h3> <ul> <li>in <strong>xintcore</strong>: recent release <code>1.2</code> introduced a bug in the subtraction (happened when 00000001 was found under certain circumstances at certain mod 8 locations).</li> </ul> <h2 id="b-20151029"><code>1.2b (2015/10/29)</code></h2> -<h3 id="bug-fixes-27">Bug fixes</h3> +<h3 id="bug-fixes-28">Bug fixes</h3> <ul> <li>in <strong>xintcore</strong>: recent release <code>1.2</code> introduced a bug in the division macros, causing a crash when the divisor started with 99999999 (it was attempted to use with 1+99999999 a subroutine expecting only 8-digits numbers).</li> </ul> @@ -785,7 +793,7 @@ License: LPPL 1.3c</code></pre> <li><p>added <code>\xintiiMaxof/\xintiiMinof</code> (<strong>xint</strong>).</p></li> <li><p>TeX hackers only: replaced all code uses of <code>\romannumeral-`0</code> by the quicker <code>\romannumeral`&&@</code> (<code>^</code> being used as letter, had to find another character usable with catcode 7).</p></li> </ul> -<h3 id="bug-fixes-28">Bug fixes</h3> +<h3 id="bug-fixes-29">Bug fixes</h3> <ul> <li>in <strong>xintexpr</strong>: recent release <code>1.2</code> introduced a bad bug in the parsing of decimal numbers and as a result <code>\xinttheexpr 0.01\relax</code> expanded to <code>0</code> ! (sigh…)</li> </ul> @@ -886,7 +894,7 @@ License: LPPL 1.3c</code></pre> <li><p><code>\xintthecoords</code> converts a comma separated list of an even number of items to the format expected by the <code>TikZ</code> <code>coordinates</code> syntax,</p></li> <li><p>completely new version <code>\xintNewExpr</code>, <code>protect</code> function to handle external macros. The dollar sign <code>$</code> for place holders is not accepted anymore, only the standard macro parameter <code>#</code>. Not all constructs are compatible with <code>\xintNewExpr</code>.</p></li> </ul> -<h3 id="bug-fixes-29">Bug fixes</h3> +<h3 id="bug-fixes-30">Bug fixes</h3> <ul> <li><p><code>\xintZapFirstSpaces</code> hence also <code>\xintZapSpaces</code> from package <strong>xinttools</strong> were buggy when used with an argument either empty or containing only space tokens.</p></li> <li><p><code>\xintiiexpr</code> did not strip leading zeroes, hence <code>\xinttheiiexpr 001+1\relax</code> did not obtain the expected result …</p></li> diff --git a/Master/texmf-dist/doc/generic/xint/README.md b/Master/texmf-dist/doc/generic/xint/README.md index db85e4b78a2..bd83ddc429f 100644 --- a/Master/texmf-dist/doc/generic/xint/README.md +++ b/Master/texmf-dist/doc/generic/xint/README.md @@ -1,8 +1,8 @@ % README -% xint 1.4i -% 2021/06/11 +% xint 1.4j +% 2021/07/13 - Source: xint.dtx 1.4i 2021/06/11 (doc 2021/06/11) + Source: xint.dtx 1.4j 2021/07/13 (doc 2021/07/13) Author: Jean-Francois Burnol Info: Expandable operations on big integers, decimals, fractions License: LPPL 1.3c diff --git a/Master/texmf-dist/doc/generic/xint/sourcexint.pdf b/Master/texmf-dist/doc/generic/xint/sourcexint.pdf Binary files differindex 4d96446c215..41147e734da 100644 --- a/Master/texmf-dist/doc/generic/xint/sourcexint.pdf +++ b/Master/texmf-dist/doc/generic/xint/sourcexint.pdf diff --git a/Master/texmf-dist/doc/generic/xint/xint.pdf b/Master/texmf-dist/doc/generic/xint/xint.pdf Binary files differindex aefccc2af7c..f9d5b3bb032 100644 --- a/Master/texmf-dist/doc/generic/xint/xint.pdf +++ b/Master/texmf-dist/doc/generic/xint/xint.pdf diff --git a/Master/texmf-dist/source/generic/xint/xint.dtx b/Master/texmf-dist/source/generic/xint/xint.dtx index c7d9ecd1163..a1ad014bc22 100644 --- a/Master/texmf-dist/source/generic/xint/xint.dtx +++ b/Master/texmf-dist/source/generic/xint/xint.dtx @@ -3,27 +3,27 @@ % Extract all files via "etex xint.dtx" and do "make help" % or follow instructions from extracted README.md. %<*dtx> -\def\xintdtxtimestamp {Time-stamp: <11-06-2021 at 22:26:15 CEST>} +\def\xintdtxtimestamp {Time-stamp: <13-07-2021 at 21:50:14 CEST>} %</dtx> %<*drv> %% --------------------------------------------------------------- -\def\xintdocdate {2021/06/11} -\def\xintbndldate{2021/06/11} -\def\xintbndlversion {1.4i} +\def\xintdocdate {2021/07/13} +\def\xintbndldate{2021/07/13} +\def\xintbndlversion {1.4j} %</drv> %<readme>% README %<changes>% CHANGE LOG -%<readme|changes>% xint 1.4i -%<readme|changes>% 2021/06/11 +%<readme|changes>% xint 1.4j +%<readme|changes>% 2021/07/13 %<readme|changes> -%<readme|changes> Source: xint.dtx 1.4i 2021/06/11 (doc 2021/06/11) +%<readme|changes> Source: xint.dtx 1.4j 2021/07/13 (doc 2021/07/13) %<readme|changes> Author: Jean-Francois Burnol %<readme|changes> Info: Expandable operations on big integers, decimals, fractions %<readme|changes> License: LPPL 1.3c %<readme|changes> %<*!readme&!changes&!dohtmlsh&!makefile> %% --------------------------------------------------------------- -%% The xint bundle 1.4i 2021/06/11 +%% The xint bundle 1.4j 2021/07/13 %% Copyright (C) 2013-2021 by Jean-Francois Burnol %<xintkernel>%% xintkernel: Paraphernalia for the xint packages %<xinttools>%% xinttools: Expandable and non-expandable utilities @@ -152,25 +152,17 @@ See `xint.pdf` for contact information. %</readme>-------------------------------------------------------- %<*changes>------------------------------------------------------- -`1.4i (2021/06/11)` +`1.4j (2021/07/13)` ---- ### Bug fixes - - **xintexpr**: simultaneous assignments via `\xintdefvar` to 10 or - more variables was broken if the right hand side was an ople (of - length at least 10, as it had prior to this release to match the - number of variables). + - **xinttools**: a brace removal bug affected the venerable `\xintSeq` + if producing a single number (e.g. `\xintSeq{10}{10}` expanded to + `10` not `{10}`). Thanks to Christophe Poulain for report. - - **xintexpr**: the mechanism which allows to define variables with - names already in use for pre-existing functions was broken for some - built-in functions: those handling syntax with dummy variables - (currently `subs()`, `subsm()`, `subsn()`, `seq()`, `add()`, `mul()`, - `ndseq()`, `ndmap()`, `ndfillraw()`) and the so-called "pseudo" - functions (currently `bool()`, `togl()`, `protect()`, `qint()`, - `qfrac()`, `qfloat()`, `qraw()`, `random()`, `qrand()`, `rbit()`). - For example the function `seq()` was broken if the user had defined a - variable `seq`. +`1.4i (2021/06/11)` +---- ### New features @@ -186,6 +178,23 @@ See `xint.pdf` for contact information. a `nutple` (which was automatically unpacked). It can now again be a number. +### Bug fixes + + - **xintexpr**: simultaneous assignments via `\xintdefvar` to 10 or + more variables was broken if the right hand side was an ople (of + length at least 10, as it had prior to this release to match the + number of variables). + + - **xintexpr**: the mechanism which allows to define variables with + names already in use for pre-existing functions was broken for some + built-in functions: those handling syntax with dummy variables + (currently `subs()`, `subsm()`, `subsn()`, `seq()`, `add()`, `mul()`, + `ndseq()`, `ndmap()`, `ndfillraw()`) and the so-called "pseudo" + functions (currently `bool()`, `togl()`, `protect()`, `qint()`, + `qfrac()`, `qfloat()`, `qraw()`, `random()`, `qrand()`, `rbit()`). + For example the function `seq()` was broken if the user had defined a + variable `seq`. + `1.4h (2021/05/27)` ---- @@ -222,6 +231,17 @@ See `xint.pdf` for contact information. `\xintTeXFrac`, `\xintTeXsignedFrac`, `\xintTeXOver`, `\xintTeXsignedOver`. The old names will emit warnings. +### New features + + - Messages written to the terminal and log file during the handling of + recovery from exceptions use a new mechanism; when in interactive + mode, the user is prompted only once, not thrice, to enter `<return>` + for recovery and continued processing. + + - **xintfrac**: `\xintTeXfromSci` (added about 7 or 8 years too late) + to help typesetting values output by `\xintfloateval` in a more + useful way than `\xintTeXFrac` (formerly `\xintFrac`). + ### Bug fixes - **xintexpr**: with **xintbinhex** loaded, `"` is recognized as prefix @@ -258,17 +278,6 @@ See `xint.pdf` for contact information. Surely, further situations remain where bad input will crash parser. -### New features - - - Messages written to the terminal and log file during the handling of - recovery from exceptions use a new mechanism; when in interactive - mode, the user is prompted only once, not thrice, to enter `<return>` - for recovery and continued processing. - - - **xintfrac**: `\xintTeXfromSci` (added about 7 or 8 years too late) - to help typesetting values output by `\xintfloateval` in a more - useful way than `\xintTeXFrac` (formerly `\xintFrac`). - `1.4f (2021/05/10)` ---- @@ -660,9 +669,9 @@ even the interface (whether to use semi-colons or colons etc...). et al. automatically unpacks the assigned value if it is a *one-ple*. If this value was in fact a *number*, low-level errors will result shortly afterwards as no check is done if the unpacking was illicit. - (Such checks exist in the codebase, but have not yet been integrated - into `\xintdefvar` by laziness). - + (update: this last remark does not apply since the `1.4i` extension to + the concept of simultaneous assignments) + - The `NumPy` concept and syntax for nested slicing and item selection are implemented. Currently *stepping* and the *Ellipsis object* are not yet available. Only so-called basic slicing is currently @@ -2890,7 +2899,13 @@ pandoc -o CHANGES.html -s --toc -V highlighting-css=' body{margin-left : 10%; \RequirePackage{ifxetex} \ifpdf \chardef\Withdvipdfmx 0 \fi -\ifxetex\chardef\Withdvipdfmx 0 \fi +\ifxetex\chardef\Withdvipdfmx 0 +% they are used at some locations in this doc + \let\pdfsetrandomseed\setrandomseed + \let\pdfuniformdeviate\uniformdeviate + \let\pdfresettimer\resettimer + \let\pdfelapsedtime\elapsedtime +\fi % Get rid of HARASSMENT by KOMA-Script \makeatletter @@ -3609,8 +3624,21 @@ pdfpagemode=UseNone,% \def\endeverbatim {\if@newlist \leavevmode\fi\endtrivlist } \@namedef{endeverbatim*}{\endeverbatim\aftergroup\everbatimundoparskip} -%\def\everbatimundoparskip{\ifdim\parskip>\z@\vskip-\parskip\fi} \def\everbatimundoparskip{\vbox{}\kern-\baselineskip\kern-\parskip} +% Note 24 juin 2021 +% +% Si everbatim[*] suit immédiatement un premier everbatim* dont l'exécution +% n'a fait que des définitions de macros sans créer de paragraphe (ou un +% environnment de liste comme center) le \kern-\parskip émis après le rendu +% verbatim (et qui vient de \everbatimundoparskip) ne sera pas compensé. +% Plus précisément le everbatim* (ou everbatim) qui vient en +% deuxième utilise \trivlist mais en ayant mis les paramètres d'espacements +% verticaux à zéro. Donc il y aura chevauchement. +% +% Pour régler ce problème, on peut : +% - soit fusionner les deux everbatim*, +% - soit si cela est embêtant, par exemple si le second environnment est +% un everbatim, pas un everbatim*, ajouter \kern-\parskip entre les deux. \def\s@everbatim {% % \ineverbtrue @@ -3675,6 +3703,10 @@ pdfpagemode=UseNone,% \def\everbatimxposthook {\pdfcolorstack\@pdfcolorstack pop\relax} \else +% Le 24 juin 2021 je vérifie que ceci est encore nécessaire avex xelatex +% (sinon color leak de OrangeRed à partir de la page 97 dans la doc) +% et aussi pour dvipdfmx (sinon color stack overflow au moment de la page 98 +% lors du passage par dvipdfmx) \ifxetex \def\everbatimxprehook {\special{color push cmyk 0 1 0.5 0}} \def\everbatimxposthook {\special{color pop}} @@ -3955,6 +3987,11 @@ pdfpagemode=UseNone,% % Someone makes the comma active (not me! not sure if doc.sty or KOMA) and % this derails xspace.sty, in the headers, as it uses \scantokens on a list of % tokens, so it fails to recognize the commas which of course are of catcode12 +% Update Friday, June 25 2021 +% I finally take the time to go to the root of this: the culprit is everbatim +% when its output crosses pagebreaks, but the same of course happens with +% verbatim. +% I opened ticket https://github.com/latex3/latex2e/issues/600 \def\xintRunningHeader{{\inheadertrue\catcode`,12\relax \DOCxintfrontpage, \DOCxintexprintro, @@ -4220,7 +4257,7 @@ pdfpagemode=UseNone,% \section {Usage} \begin{itemize} -\item To use with |etex|, |pdftex|, ..., i.e. with \TeX{} engines activating +\item To use with |etex|, |pdftex|, ..., i.e.\@ with \TeX{} engines activating the e\TeX{} extensions: \begin{everbatim} \input xintexpr.sty @@ -4257,8 +4294,8 @@ but in this documentation I might be using simply |Digits| to refer to it. The tables of the built-in \hyperref[tab:precedences]{operators} and \hyperref[tab:functions]{functions} will give a quick overview of the available syntax. -The simplest way to test the syntax is to\footnote{I am assuming here Mac OS or Linux, -adapt to your environment} work interactively on the command line +The simplest way\footnote{I am assuming here Mac OS or Linux, +adapt to your environment} to test the syntax is to work interactively on the command line (this feature is available since April 2021, the version of \ctanpackage{xintsession} used here is |1.3a|): \begin{everbatim} @@ -4312,7 +4349,7 @@ quality of the document). Reports welcome.% \footnote{Thanks to Jürgen Gilg for keeping the author motivated and helping proof-read the 1.4 documentation.} -\subsection{Improved support for logarithm, exponential, sine, etc... at +\subsection{Improved support for logarithm, exponential, sine, etc...\@ at the \texttt{1.4e} release of \texttt{2021/05/05}} They are now supported up to \dtt{62} digits and achieve «correct rounding»% @@ -4326,8 +4363,8 @@ at least in \dtt{99\%} of cases% % \footnote{It is even better than that, but depends a bit on how |Digits| is - located relative to some thresholds deciding where to cut some Taylor series - or other mathematical means.} + located relative to some thresholds governing Taylor series + or other approximation means.} % for |Digits| being at least \dtt{9}. @@ -4496,7 +4533,7 @@ For bugfixes and possibly more details check |CHANGES.html|: \item Also the second argument of \func{trunc} and \func{round} can be negative (but then it enacts quantization, e.g |trunc(1234,-2)| produces - \dtt{\xinteval{trunc(1234,-2)}}. Matching updates to the support + \dtt{\xinteval{trunc(1234,-2)}}). Matching updates to the support macros \csbxint{Trunc}, \csbxint{Round}, \csbxint{iTrunc}, and \csbxint{iRound}. @@ -4523,7 +4560,7 @@ author a few decades to finish absorbing Python/NumPy. \begin{itemize} \item \xintexprname |1.4| requires the |\expanded| primitive, which is provided by all major \TeX{} engines since \TeX Live 2019. The macro - packages \xintname, \xintfracname, \xinttoolsname et al. do not (yet) + packages \xintname, \xintfracname, \xinttoolsname et al.\@ do not (yet) require |\expanded|. It is probable also |\pdfstrcmp| (|\strcmp|) will be required at some point @@ -4559,7 +4596,8 @@ author a few decades to finish absorbing Python/NumPy. \item[if(100>0,(100,125),(100,128)) breaks my code:] % This is a feature. This is a syntax error, as the comma serves to contatenate - "oples" (see \autoref{oples}), so it is parsed to behave as + "oples" (see \autoref{oples}), and parentheses do not create analogs of + "tuples", so this input is parsed the same as \begin{everbatim} if(100>0,100,125,100,128) \end{everbatim} @@ -4603,7 +4641,7 @@ author a few decades to finish absorbing Python/NumPy. \item[{I liked the ``broadcasting'' \detokenize{[1..10]^10} syntax, but it was removed at 1.4}] % - Patience... |seq(x^10,x=1..10)| is alternative (add external |[..]| to get + Patience...\@ |seq(x^10,x=1..10)| is alternative (add external |[..]| to get a nutple). \item[{\detokenize{1e\numexpr5+2\relax} crashes}] % @@ -4657,7 +4695,7 @@ with targets such as |xint.pdf| or |sourcexint.pdf|. Even if your system does not allow executing |make|, the rules it contains can be imitated manually (if possible using |Latexmk|). -Back to \TeX\ distributions with a |"texdoc"| or similar utility, +With \TeX\ distributions providing a |"texdoc"| or similar utility, \centeredline{|texdoc --list xint|} gives the choice to display one of: \begin{itemize}[nosep] @@ -4735,7 +4773,7 @@ Our category $\mathcal{C}$ of «oples» is the smallest collection of Notes: \begin{itemize} \item -We denote the empty set \dtt{$\emptyset$} by \emph{nil}.% +We refer to the empty set \dtt{$\emptyset$} via the variable \emph{nil}.% % \footnote{There is actually a built-in variable with this name. At |1.4|, |\xintexpr\relax| is @@ -4764,10 +4802,15 @@ unpacking of sequence type objects). In the expression input syntax it corresponds to enclosing \dtt{$O$} within square brackets: \dtt{$[O]$}. \item A braced \emph{ople} is called a \emph{nutple}. Among them \dtt{\{nil\}} - is a bit special. It is called the \emph{not-ple}. It is not \dtt{nil}.% + (aka $\{\emptyset\}$) is a bit special. It is called the \emph{none-ple}.% +% + \footnote{Prior to version |1.4j| of this documentation it was called the + \emph{not-ple}.} +% +It is not \dtt{nil}.% % \footnote{There is (experimental) a pre-defined «\dtt{None}» variable which - stands for the \emph{not-ple}. It can also be input as |[]|.} + stands for the \emph{none-ple}. It can also be input as |[]|.} \end{itemize} Each \emph{ople} has a \emph{length} which is its cardinality as set. The @@ -4779,8 +4822,8 @@ singleton |oples| are called \emph{one-ples}. There are thus two types of \end{itemize} If we consider the empty set |nil| on the same footing as |atoms|, the two -types have only one common object which is the \emph{not-ple}. As a rule -arithmetic operations will either break or silently convert the \emph{not-ple} +types have only one common object which is the \emph{none-ple}. As a rule +arithmetic operations will either break or silently convert the \emph{none-ple} to the zero value: \begin{everbatim*} \xinteval{3+[], 5^[], 10*[]} @@ -4813,16 +4856,17 @@ utterances, due to legacy reasons from the pre-|1.4| internal model), we synonymous to \emph{element} in the set-theoretical sense. To repeat, any ople \dtt{$O$} is a finite totally ordered set: if not the empty -set, it has elements \dtt{$a_1$}, \dots, \dtt{$a_k$}, and the above means that +set, it has \emph{elements} \dtt{$a_1$}, \dots, \dtt{$a_k$}, and the above means that its \emph{items} are the singleton oples (aka one-ples) \dtt{$I_1=\{a_1\}$}, \dots, \dtt{$I_k=\{a_k\}$}. Each \dtt{$a_j$} may be an |atom|, then -\dtt{$I_j$} is a |number|, or an |ople| (possibly the empty set), then -\dtt{$I_j$} is a |nutple| whose depth is one more then the one of the ople +\dtt{$I_j$} is a |number|, or \dtt{$a_j$} is an |ople| (possibly the empty set), then +\dtt{$I_j$} is a |nutple| whose depth is one more than the one of the ople \dtt{$a_j$}. Thus we can refer to «items» but must then understand they are not «elements»: -«items» are «singleton sub-sets». The length of an ople is the number of its -items. It is tempting to use «sub-item» to keep in mind they are «sub-sets» +«items» are «singleton sub-sets». The cardinality (aka length) of an ople is +also the number of its +items. It would be tempting to use the terminology «sub-item» to keep in mind they are «sub-sets» but this would again create confusion: a |nutple| has only one item which is itself; and we need some terminology to refer to the individual numbers in the |nutple| given in input as |[1,2,3]| for example. It is natural to refer to @@ -4832,8 +4876,8 @@ is in particular an «item» of itself, the unique one at that). We distinguish the |oples| of length zero (there is only one, the empty set) or at least two as those which can never be an «item». Those of length one, the |one-ples|, are exactly those which can be «items». Among them some may -have «sub-items», they are the |nutples| with the exception of the |not-ple|, -others can't, they are the |numbers| and the |not-ple| (whose input syntax is +have «sub-items», they are the |nutples| with the exception of the |none-ple|. +And the others do not have «sub-items», they are the |numbers| and the |none-ple| (whose input syntax is either |[]| or the variable |None|).% % \footnote{% @@ -4873,7 +4917,7 @@ also a \emph{leaf}. Else the children at top level are the successive % Among the elements some are \emph{atoms} giving \emph{leaves} of the tree, others are \emph{nutples} which in turn have children. In the special case of -the \emph{not-ple} we consider it has a child, which is the empty set and this +the \emph{none-ple} we consider it has a child, which is the empty set and this is why we consider the empty set |nil| to be also a potential \emph{leaf}. We then proceed recursively. We thus obtain from the root \emph{ople} a tree whose vertices are either \emph{oples} or \emph{leaves}. Only the empty set @@ -4911,7 +4955,7 @@ than display it. «Set-theoretical» slicing of an \emph{ople} means replacing it with one of its subsets. This applies also if it is a \emph{number}. Then it can be sliced only to itself or to the empty set (indeed it has only one element, which is -an atom). Similarly the \emph{not-ple} can only be sliced to give itself or +an atom). Similarly the \emph{none-ple} can only be sliced to give itself or the empty set. And more generally a \emph{nutple} is a singleton so also can only be set-sliced to either the empty set or itself. @@ -4920,12 +4964,12 @@ only be set-sliced to either the empty set or itself. \item if they are not \emph{nutples} set-theoretical slicing applies, \item if they are \emph{nutples} (only case having a one-to-one correspondence in Python) then the slicing happens \emph{within brackets}: - i.e. the \emph{nutple} is unpacked then the set-theoretical slicing is + i.e.\@ the \emph{nutple} is unpacked then the set-theoretical slicing is applied, then the result is \emph{repacked} to produce a new \emph{nutple}. \end{itemize} -With these conventions the \emph{not-ple} for example is invariant under +With these conventions the \emph{none-ple} for example is invariant under slicing: unpacking it gives the empty set, which has only the empty set as -subset and repacking gives back the \emph{not-ple}. Slicing a general +subset and repacking gives back the \emph{none-ple}. Slicing a general \emph{nutple} returns a \emph{nutple} but now of course in general distinct from the first one. @@ -4943,13 +4987,13 @@ a set). \begin{itemize}[nosep] \item if they are not \emph{nutples} set-theoretical item indexing applies, \item if they are \emph{nutples} (only case having a one-to-one - correspondence in Python) then the meaning becomes \emph{extracting}: i.e. + correspondence in Python) then the meaning becomes \emph{extracting}: i.e.\@ the \emph{nutple} is unpacked then the set-theoretical indexing is applied, but the result is \emph{not repacked}. \end{itemize} -For example when applied to the \emph{not-ple} we always obtain -the |nil|. Whereas as we saw slicing the \emph{not-ple} always gives back the -\emph{not-ple}. Indexing is denoted in the syntax by postfixing by |[N]|. Thus +For example when applied to the \emph{none-ple} we always obtain +the |nil|. Whereas as we saw slicing the \emph{none-ple} always gives back the +\emph{none-ple}. Indexing is denoted in the syntax by postfixing by |[N]|. Thus for \emph{nutples} (which are analogous to Python objects), there is genuine difference between the |[N]| extractor and the |[N:N+1]| slicer. But for \emph{oples} which are either |nil|, a \emph{number}, or of length at least 2, @@ -4997,7 +5041,7 @@ is delimited by the opening and closing parentheses, then it applies the function body, after having mapped the successive items (not the elements) of the parsed ople to the variables appearing in the function call signature. Hence the arguments in the call signature stand for |one-ples| -(i.e. either |numbers| or |nutples|). +(i.e.\@ either |numbers| or |nutples|). Let me explain why we can not define a function |foo(A,B)| of two oples: the function call will evaluate as an ople what is enclosed within the @@ -5031,7 +5075,7 @@ will then occupy the place of as many arguments as its cardinality (which is its number of elements, hence of its associated items). For example if function |foo| was declared as a function of 5 arguments |f(a,b,c,d,e)| it is legitimate to use it as |f(A,B)| if |A| is an ople-valued variable of length -tree and |B| of length two. The actual arguments |a,b,c,d,e| will be made to +three and |B| of length two. The actual arguments |a,b,c,d,e| will be made to match the three items of |A| and the two items of |B|. \subsubsection{Final words on leaves} @@ -5086,7 +5130,7 @@ to handle arbitrarily big integers or arbitrary float precision.}. % These \eTeX{} extensions date back to 1999 and are by default incorporated into the |pdftex| -etc... executables from major modern \TeX{} installations for more than +etc...\@ executables from major modern \TeX{} installations for more than fifteen years now. \begin{itemize} @@ -5217,7 +5261,7 @@ standard catcodes and thus will get retokenized and the typesetter macro (which being |\protected| is there intact in external file) will expand as expected. -One needs \csbxint{eval} et al. only if one really wants the final digits (and +One needs \csbxint{eval} et al.\@ only if one really wants the final digits (and other characters), for example in a context where \TeX{} expects a number or a dimension. @@ -5400,7 +5444,7 @@ definitions: Attention! The above macros convert from \xintexprname internal numeric data format to «printed» output; they are thus susceptible to require adjustments if the internal data format changes, which may happen at each release. Of course -the default for |\xintexprPrintOne| etc... will be adjusted accordingly, but +the default for |\xintexprPrintOne| etc...\@ will be adjusted accordingly, but user custom definitions may break. The interface for \csbxint{floatexprPrintOne} was changed.\CHANGED{1.4e} @@ -5866,9 +5910,10 @@ precedence, use parentheses for disambiguation. \end{description} \item[|\relax|] This is the expression terminator for \csbxint{expr} et al. - It may arise from expansion during the parsing itself. As alternative use - \csbxint{eval} et al. which proceed as macros expecting one mandatory - argument. + It may arise from expansion during the parsing itself. As alternative to + \csbxint{expr} (et al.) use + \csbxint{eval} (et al.) which have the usual macro interface (with one mandatory + argument). \end{description} The |;| also serves as syntax terminator for \csbxint{defvar} and @@ -5969,7 +6014,7 @@ Miscellaneous notes: % listparindent=\leftmarginiii] \funcdesc[]{random} returns a random float |x| verifying |0 <= x < 1|. It obeys - the prevailing precision as set by \csbxint{Digits}: i.e. with |P| being the + the prevailing precision as set by \csbxint{Digits}: i.e.\@ with |P| being the precision the random float multiplied by |10^P| is an integer, uniformly distributed in the |0..10^P-1| range. @@ -5986,7 +6031,7 @@ Miscellaneous notes: \end{everbatim*} \funcdesc[]{qrand} returns a random float |0 <= x < 1| using \dtt{16} digits of - precision (i.e. |10^{16}x| is an integer). This is provided when speed is a + precision (i.e.\@ |10^{16}x| is an integer). This is provided when speed is a at premium as it is optimized for precision being precisely \dtt{16}.% \begin{everbatim*} @@ -6074,7 +6119,7 @@ Recall that this is NOT done automatically, for example when adding fractions. \item[ilog10(x)]\hypertarget{func:ilog10-ii} in |\xintiiexpr| the integer exponent $a$ such that $10^a\leq \mathrm{abs}(x)< 10^{a+1}$; returns (this may evolve in future) - \dtt{\xintiieval{ilog10(0)}} if $x$ vanishes (i.e. \dtt{0x7fff8000}). + \dtt{\xintiieval{ilog10(0)}} if $x$ vanishes (i.e.\@ \dtt{0x7fff8000}). \begin{everbatim*} \xintiieval{ilog10(1), ilog10(-1234567), ilog10(-123456789123456789), ilog10(2**31)}\par \end{everbatim*} @@ -6359,7 +6404,7 @@ $\xintthefloatexpr subs(((x-1)/x, x/x, (x+1)/x), x=2**30)\relax \end{everbatim*} If the input vanishes the function outputs - \dtt{\xinteval{ilog10(0)}} (i.e. |-0x7fff8000| which is near the + \dtt{\xinteval{ilog10(0)}} (i.e.\@ |-0x7fff8000| which is near the minimal TeX number |-0x7fffffff|). This is also subject to change. The \hyperlink{func:ilog10-ii}{integer-only} variant for \csbxint{iiexpr} @@ -6398,7 +6443,7 @@ $\xintthefloatexpr subs(((x-1)/x, x/x, (x+1)/x), x=2**30)\relax in first case if |A| is zero or negative and in second case if |B <= A|. Attention that the arguments are first converted to integers using - \csbxint{Num} (i.e. truncated towards zero). + \csbxint{Num} (i.e.\@ truncated towards zero). The function can be used in all three parsers. Of course the size is not limited (but in the float parser, the integer will be rounded if involved @@ -6537,7 +6582,7 @@ mod(11/7,1/13)- (11/7)/:(1/13), (11/7)//(1/13)\relax\newline \end{everbatim*} The arguments must be (expand to) short integers. - \funcdesc[a, b]{pfactorial} computes partial factorials i.e. + \funcdesc[a, b]{pfactorial} computes partial factorials i.e.\@ |pfactorial(a,b)| evaluates the product |(a+1)...b|. \begin{everbatim*} \xinttheexpr seq(pfactorial(20, i), i=20..30)\relax @@ -6932,7 +6977,7 @@ like extracting directly), but it is leaner to drop the extra «packing». You can try with |\xintDigits:=1004\relax| and |2e-501| in place of |\xintDigits:=87\relax| and |2e-43|, but be patient for some seconds for the result. Of course don't truncate the final - result to only \dtt{83} fractional decimal digits but \dtt{1000}... + result to only \dtt{83} fractional decimal digits but \dtt{1000}...\@ and better to wrap the whole thing in |\message| or |\immediate\write128| or |\edef| because it will then run in the right margin. @@ -6947,7 +6992,7 @@ like extracting directly), but it is leaner to drop the extra «packing». \footnote{Prior to |1.4|, one could use |@| in |rrseq()| and |iterr()| as an alias to |@1|. This undocumented feature is dropped and |@| will break |rrseq()| and |iterr()|.} % - Using |rrseq()| with |@1| etc... accessors may be perhaps a bit + Using |rrseq()| with |@1| etc...\@ accessors may be perhaps a bit more efficient than using |rseq()| with a list as staring value and constructs such as |@[0]|, |@[1]| (or rather |@[-1]|, |@[-2]| to mimick what |@1|, |@2|, |@3|, |@4| and |@@(integer)| do in |rrseq()|. @@ -7089,7 +7134,7 @@ First Fibonacci number at least |2^31| and its index On the other hand integers from |\xintexpr 1..10\relax| are already in raw \xintfracname format for example |3/1[0]| which speeds up their usage - in the macros internally involved in computations... thus perhaps what one + in the macros internally involved in computations...\@ thus perhaps what one gains on one side is lost on the other side. \item |a..[d]..b| generates «real» numbers along arithmetic progression @@ -7102,7 +7147,7 @@ First Fibonacci number at least |2^31| and its index \end{everbatim*} At |1.4|,\CHANGED{1.4} this generator behaves in \csbxint{floatexpr} exactly as in - \csbxint{expr}, i.e. \emph{exactly}. This is breaking + \csbxint{expr}, i.e.\@ \emph{exactly}. This is breaking change. \begin{everbatim*} \xintDigits:=6; @@ -7208,7 +7253,7 @@ more. Notice though that our interpretation of the syntax is more general than NumPy's concepts (of basic slicing/indexing): \begin{itemize} -\item slicing and itemizing apply also to non-bracketed objects i.e. \emph{oples}, +\item slicing and itemizing apply also to non-bracketed objects i.e.\@ \emph{oples}, \item the leaves do not have to be all at the same depth, \item there are never any out-of-range index errors: out-of-range indices are silently ignored. @@ -7230,7 +7275,7 @@ secondExtractedScalar = \xintexpr myArray[0,1,0]\relax\par \end{everbatim*} As said before, \emph{stepping} is not yet implemented. Also the NumPy -extension to Python for item selection (i.e. via a |tuple| of comma separated +extension to Python for item selection (i.e.\@ via a |tuple| of comma separated indices) is not yet implemented. \subsection{Tacit multiplication} @@ -7678,7 +7723,7 @@ have gained experience in using this interface...): \xintdeffunc bar(x) := \xintfloatexpr bar(float(x))\relax; \end{everbatim} With this the transplanted float-function will expand in \csbxint{expr} as - it would have in \csbxint{floatexpr}, i.e. using float operations; this is + it would have in \csbxint{floatexpr}, i.e.\@ using float operations; this is different from declaring the function again with the same expression as used for the original, as it would have then been parsed with a mapping of infix operators to the macros doing the exact operations, not the floating point @@ -7758,7 +7803,7 @@ At |1.4| we did some obstinate work to make this working but: \end{itemize} Conclusion: if some \csbxint{deffunc} break, check if it does not fit the -above criterion before reporting... and recall \csbxint{NewFunction} is your +above criterion before reporting...\@ and recall \csbxint{NewFunction} is your friend. It has the big advantage of declaring a function for all parsers simultaneously! @@ -7766,7 +7811,7 @@ A special note on \func{subs}: it is and has always been hopeless in \csbxint{de context. All it does (if it works at all) after being malaxed by \csbxint{deffunc} is to copy over at the indicated places the \emph{recipe} to compute something. Thus at every location where that something is needed it will be -evaluated from scratch again. Yes, this is disappointing. But... on the other +evaluated from scratch again. Yes, this is disappointing. But...\@ on the other hand the more general \func{seq} does work, or pretends to work. Let me illustrate to make thinks clear. We start with this: \begin{everbatim*} @@ -8031,7 +8076,7 @@ $$ $$ \end{everbatim*}% For some hair-raising experience check the \csbxint{verbosetrue} output in the -log... here is an alternative with two (three, counting |dprod()|) helper +log...\@ here is an alternative with two (three, counting |dprod()|) helper functions: \begin{everbatim*} % annoying that Tr also starts Trace, but Spur is available @@ -8222,7 +8267,7 @@ This package was first included in release |1.3e| (|2019/04/05|) of At |1.4e| (|2021/05/05|) the accuracy was significantly increased:\CHANGED{1.4e} formerly the high-level user interface used to define the functions had as consequences that intermediate steps of the computations -could not operate with guard digits, and as a result so the last two digits +could not operate with guard digits, and as a result the last two digits were most of the time off (at least the last one). Now, computations are done internally in extended precision, and the accuracy is high up to the last digits, with faithful rounding and high probability of correct rounding. And @@ -8677,7 +8722,7 @@ anecdotical evidence showing it is good. \renewcommand{\etocaftertochook}{\addvspace{\bigskipamount}} \part{The macro layer for expandable computations: \xintcorename, \xintname, - \xintfracname,...} + \xintfracname,...\@} \RaisedLabel[15]{sec:bundle} @@ -8772,7 +8817,7 @@ traps\dots,\footnote{The latter exist as work-in-progress for some time in the source code.} have not been implemented, only the notion of `scientific notation with a given number of significant figures'.% % -\footnote{multiplication of two floats with |P=\xinttheDigits| digits is +\footnote{Multiplication of two floats with |P=\xinttheDigits| digits is first done exactly then rounded to |P| digits, rather than using a specially tailored multiplication for floating point numbers which would be more efficient (it is a waste to evaluate fully the @@ -8928,7 +8973,7 @@ before further processing. Formerly, the initial rounding was done to |P+2| digits (and at least |P+3| for the power operation.) The more ambitious model would be for the computing macros to obey the -intrinsic precision of their inputs, i.e. to compute the correct rounding to +intrinsic precision of their inputs, i.e.\@ to compute the correct rounding to |P| digits of the exact mathematical result corresponding to inputs allowed to have their own higher precision.% % @@ -8985,7 +9030,7 @@ An expandable macro can not execute a |\def| or an |\edef|. But the macro must expand its arguments to find the digits it is supposed to manipulate. \TeX{} provides a tool to do the job of (expandable !) repeated expansion of the first token found until hitting something non expandable, such as a digit, a -|\def| token, a brace, a |\count| token, etc... is found. A space token also +|\def| token, a brace, a |\count| token, etc...\@ is found. A space token also will stop the expansion (and be swallowed, contrarily to the non-expandable tokens). @@ -9170,7 +9215,7 @@ margin annotation signals what is the argument type. \item the fraction input format\ntype{\Ff} applies to the arguments of \xintfracname macros handling genuine fractions. It allows two types of inputs: general and restricted. The restricted type is parsed faster, - but... is restricted. + but...\@ is restricted. \begin{description} \item[general:] inputs of the shape |A.BeC/D.EeF|. Example: \begin{everbatim*} @@ -9278,7 +9323,7 @@ and |B| are integers, |B| is positive, and |N| is a ``short'' integer. The output is not reduced to smallest terms. The |A| and |B| may end with zeroes (\emph{i.e}, |N| does not represent all powers of ten). The denominator |B| is always strictly positive. There is no |+| sign. The |-| is always first if -present (i.e. the denominator on output is always positive.) The output will +present (i.e.\@ the denominator on output is always positive.) The output will be expressed as such a fraction even if the inputs are both integers and the mathematical result is an integer. The |B=1| is not removed.% % @@ -9290,7 +9335,7 @@ sign and is followed by a dot and |P-1| digits. Trailing zeroes are not trimmed. There is one exceptional case: \begin{itemize}[nosep] \item if the value is mathematically zero, it is output as |0.e0|, - i.e. zeros after the decimal mark are removed and the exponent is always |0|. + i.e.\@ zeros after the decimal mark are removed and the exponent is always |0|. \end{itemize} Future versions of the package may modify this. \end{itemize} @@ -9544,7 +9589,7 @@ recover the $1238/1157$ therein! \end{framed} -\subsection{\csh{ifcase}, \csh{ifnum}, ... constructs}\label{sec:ifcase} +\subsection{\csh{ifcase}, \csh{ifnum}, ...\@ constructs}\label{sec:ifcase} When using things such as |\ifcase \xintSgn{\A}| one has to make sure to leave a space after the closing brace for \TeX{} to @@ -9798,7 +9843,7 @@ have any underscore in their names (for obscure legacy reasons). \xinttoolsname will not overwrite them. The same meanings are independently available under the names |\xintodef|, |\xintoodef|, etc... -Apart from |\thexintexpr|, |\thexintiexpr|, ... +Apart from |\thexintexpr|, |\thexintiexpr|, ...\@ all other public macros from the \xintname bundle packages start with |\xint|. For the good functioning of the macros, standard catcodes are assumed for the @@ -9824,8 +9869,8 @@ temporarily turn off potentially active characters. \label{ssec:origins} |2013/03/28.| Package |bigintcalc| by \textsc{Heiko Oberdiek} already -provides expandable arithmetic operations on ``big integers'', -exceeding the \TeX{} limits (of $2^{31}-1$), so why another% +provides expandable arithmetic operations on «big integers», i.e. integers +beyond the \TeX\ bound $2^{31}-1$, so why another% % \footnote{this section was written before the \xintfracname package; the author is not aware of another package allowing expandable @@ -9897,7 +9942,7 @@ $5000$ and $10000$ respectively. The \xintkernelname package contains mainly the common code base for handling the load-order of the bundle packages, the management of catcodes at loading time, definition of common constants and macro utilities which are used -throughout the code etc ... it is automatically loaded by all packages of the +throughout the code etc ...\@ it is automatically loaded by all packages of the bundle. It provides a few macros possibly useful in other contexts. @@ -10004,7 +10049,7 @@ argument first. \label{xintFirstOne} \csa{xintFirstOne}\marg{list}\etype{n} returns the first item as a braced -item. I.e. if it was braced the braces are kept, else the braces are added. +item. i.e.\@ if it was braced the braces are kept, else the braces are added. It looks like using \csbxint{FirstItem} within braces, but the difference is when the input was empty. Then the output is empty.\NewWith{1.4} @@ -10014,7 +10059,7 @@ It does no expansion, which should be obtained via suitable |\expandafter|'s. \label{xintLastOne} \csa{xintLastOne}\marg{list}\etype{n} returns the last item as a braced -item. I.e. if it was braced the braces are kept, else the braces are added. +item. i.e.\@ if it was braced the braces are kept, else the braces are added. It looks like using \csbxint{LastItem} within braces, but the difference is when the input was empty. Then the output is empty.\NewWith{1.4} @@ -10088,7 +10133,7 @@ avoids having to insert absolute values in formulas. The underlying engine Random Number Generator works with an array of 55 28bits integers. To produce a « uniform » random integer in a given range \dtt{0..x-1} it produces next pseudo-random |y| (supposedly uniformly -distributed, i.e. non-uniformity can be neglected) such that \dtt{$0\leq y < +distributed, i.e.\@ non-uniformity can be neglected) such that \dtt{$0\leq y < 2^{28}$} and the output is the rounding of \dtt{$x*(y/2^{28})$}, with upper bound |x| remapped to |0|. This has following corollaries: \begin{enumerate} @@ -10282,7 +10327,7 @@ All macros require strict integer format on input and produce strict integer format on output, except:\IMPORTANT \begin{itemize}[nosep] \item \csbxint{iNum} which converts to strict integer format an input in - \emph{extended} integer format, i.e. admitting multiple leading plus or + \emph{extended} integer format, i.e.\@ admitting multiple leading plus or minus signs, then possibly leading zeroes, then digits, \item and \csbxint{Num} which is an alias for the former, which gets redefined by \xintfracname to accept more generally also decimal numbers or fractions as @@ -10365,17 +10410,17 @@ truncated towards zero. \subsection{\csh{xintDSL}}\label{xintDSL} -|\xintDSL|\n\etype{f} is decimal shift left, \emph{i.e.} multiplication by +|\xintDSL|\n\etype{f} is decimal shift left, \emph{i.e.\@} multiplication by ten. \subsection{\csh{xintDSR}}\label{xintDSR} -|\xintDSR|\n\etype{f} is truncated decimal shift right, \emph{i.e.} it is the +|\xintDSR|\n\etype{f} is truncated decimal shift right, \emph{i.e.\@} it is the truncation of |N/10| towards zero. \subsection{\csh{xintDSRr}}\label{xintDSRr} -|\xintDSRr|\n\etype{f} is rounded decimal shift right, \emph{i.e.} it is the +|\xintDSRr|\n\etype{f} is rounded decimal shift right, \emph{i.e.\@} it is the rounding of |N/10| away from zero. It is needed in \xintcorename for use by \csbxint{iiDivRound}. @@ -10627,7 +10672,7 @@ inputs: decimal, scientific numbers, fractions. The |ii| macros provided here by \xintname can be nested inside macros of \xintfracname but the opposite does not apply, because the output format of the \xintfracname macros, even for representing integers, is not understood by the |ii| macros. The «Boolean -macros» \csbxint{AND} etc... are exceptions though, they work fine if served +macros» \csbxint{AND} etc...\@ are exceptions though, they work fine if served as inputs some \xintfracname output, despite doing only \fexpan sion. Prior to |1.2o|, these macros did apply the \csbxint{Num} or the more general \xintfracname general parsing, but this overhead was @@ -10739,7 +10784,7 @@ by |10^x| hence produces |0| if |N=0| whereas \subsection{\csh{xintDSH}}\label{xintDSH} |\xintDSH|\x\n\etype{\numx f} is parametrized decimal shift. When |x| is -negative, it is like iterating \csbxint{DSL} \verb+|x|+ times (\emph{i.e.} +negative, it is like iterating \csbxint{DSL} \verb+|x|+ times (\emph{i.e.\@} multiplication by $10^{-x}$). When |x| positive, it is like iterating \csbxint{DSR} |x| times (and is more efficient), and for a non-negative |N| this is thus the same as the quotient from the Euclidean division by |10^x|. @@ -10766,7 +10811,7 @@ positive, and |N = 10^x Q - R| if |Q| turns out to be negative, which is exactly the case when |N| is at most |-10^x|. |\xintDSx|\x\n\etype{\numx f} for |x| negative is exactly as -|\xintDSH|\x\n, \emph{i.e.} multiplication by $10^{-|x|}$. For |x| zero or +|\xintDSH|\x\n, \emph{i.e.\@} multiplication by $10^{-|x|}$. For |x| zero or positive it returns the two numbers |{Q}{R}| described above, each one within braces. So |Q| is |\xintDSH|\x\n, and |R| is |\xintDSHr|\x\n, but computed simultaneously. @@ -11079,14 +11124,14 @@ $b-a$ is not too large, one may use an ad hoc function definition such as: \subsection{\csh{xintiiMax}}\label{xintiiMax} |\xintiiMax|\n\m\etype{ff} returns the largest of the two in the sense -of the order structure on the relative integers (\emph{i.e.} the right-most +of the order structure on the relative integers (\emph{i.e.\@} the right-most number if they are put on a line with positive numbers on the right): |\xintiiMax {-5}{-6}|\dtt{=\xintiiMax{-5}{-6}}. \subsection{\csh{xintiiMin}}\label{xintiiMin} |\xintiiMin|\n\m\etype{ff} returns the smallest of the two in the sense of the -order structure on the relative integers (\emph{i.e.} the left-most number if +order structure on the relative integers (\emph{i.e.\@} the left-most number if they are put on a line with positive numbers on the right): |\xintiiMin {-5}{-6}|\dtt{=\xintiiMin{-5}{-6}}. @@ -11151,25 +11196,25 @@ otherwise. \subsection{\csh{xintXOR}}\label{xintXOR} |\xintXOR{f}{g}|\etype{ff} returns \dtt{1} if exactly one of |f| or |g| -is true (i.e. non-zero), else \dtt{0}. +is true (i.e.\@ non-zero), else \dtt{0}. \subsection{\csh{xintANDof}}\label{xintANDof} \csa{xintANDof}|{{a}{b}{c}...}|\etype{f{$\to$}\lowast f} returns \dtt{1} if -all are true (i.e. non zero) and \dtt{0} otherwise. The list argument may be a +all are true (i.e.\@ non zero) and \dtt{0} otherwise. The list argument may be a macro, it (or rather its first token) is \fexpan ded first to deliver its items. \subsection{\csh{xintORof}}\label{xintORof} \csa{xintORof}|{{a}{b}{c}...}|\etype{f{$\to$}\lowast f} returns \dtt{1} if at -least one is true (i.e. does not vanish), else it produces \dtt{0}. The list +least one is true (i.e.\@ does not vanish), else it produces \dtt{0}. The list argument may be a macro, it is \fexpan ded first. \subsection{\csh{xintXORof}}\label{xintXORof} \csa{xintXORof}|{{a}{b}{c}...}|\etype{f{$\to$}\lowast f} returns \dtt{1} if an -odd number of them are true (i.e. do not vanish), else it produces \dtt{0}. +odd number of them are true (i.e.\@ do not vanish), else it produces \dtt{0}. The list argument may be a macro, it is \fexpan ded first. \subsection{\csh{xintiiGCD}} @@ -11421,7 +11466,7 @@ their macro definitions. Only these two are redefined: \hyperref[xintNumFrac]{\string\xintNum} and \hyperref[xintLenFrac]{\string\xintLen}. As explained in \autoref{ssec:inputs} and \autoref{ssec:outputs} the interchange format for the \xintfracname -macros, i.e. |A/B[N]|, is not understood by the |ii|-named macros of +macros, i.e.\@ |A/B[N]|, is not understood by the |ii|-named macros of \xintcorename/\xintname which expect the so-called strict integer format. Hence, to use such an |ii|-macro with an output from an \xintfracname macro, an extra \csbxint{Num} wrapper is required. But macros already defined by @@ -13687,7 +13732,7 @@ between% \leftedline{|\xintRationalSeries {A}{B}{\first}{\ratio{\g}}|} % \leftedline{and |\xintRationalSeriesX {A}{B}{\first}{\ratio}{\g}|.} First the -location of braces differ... then, in the former case |\first| is a +location of braces differ...\@ then, in the former case |\first| is a \emph{no-parameter} macro expanding to a fractional number, and in the latter, it is a \emph{one-parameter} macro which will use |\g|. Furthermore the |X| variant @@ -14102,7 +14147,7 @@ efficient chaining of such series evaluations. In this final section, the use of \csbxint{FxPtPowerSeries} (and \csbxint{PowerSeries}) will be -illustrated on the (expandable... why make things simple when it is so easy to +illustrated on the (expandable...\@ why make things simple when it is so easy to make them difficult!) computations of the first digits of the decimal expansion of the familiar constants $\log 2$ and $\pi$. @@ -14328,7 +14373,7 @@ laptop (a 2012 model) this took about $5.05$ seconds last time I tried.% for example digits are represented and manipulated via their ascii-code ! all computations must convert from ascii-code to cpu words; furthermore nothing can be stored away. And there is no memory storage with |O(1)| time - access... if expandability is to be verified.} + access...\@ if expandability is to be verified.} % @@ -15635,7 +15680,7 @@ job without the initial expansion of the \meta{list} argument. parameter macro |\macro| to each item in the \meta{list} given as second argument and returns a new list with these outputs: each item is given one after the other as parameter to |\macro| which is expanded at that time (as usual, -\emph{i.e.} fully for what comes first), the results are braced and output +\emph{i.e.\@} fully for what comes first), the results are braced and output together as a succession of braced items (if |\macro| is defined to start with a space, the space will be gobbled and the |\macro| will not be expanded; it is allowed to have its own arguments, the list items serve as last arguments to @@ -16871,7 +16916,7 @@ The main problems are caused by active characters, because \csbxint{expr} et al.\@ expand forward whatever comes from token stream; they apply |\string| only in a second step. For example the catcode of |&| from |&&| Boolean disjunction is not really important as long as it is not active, or comment, -or escape... or brace... or ignored... in brief, as long as it is reasonable, +or escape...\@ or brace...\@ or ignored...\@ in brief, as long as it is reasonable, and in particular whether |@| is of catcode letter or other does not matter. It is always possible to insert manually the |\string| in the expression @@ -17013,7 +17058,7 @@ numbers and towards $-\infty$ for negative ones. An optional parameter |D| within brackets, immediately after |\xintiexpr| is allowed: it instructs (for |D>0|) the expression to do its final rounding to -the nearest value with that many digits after the decimal mark, \emph{i.e.}, +the nearest value with that many digits after the decimal mark, i.e.\@ |\xintiexpr [D] <expression>\relax| is equivalent (in case of a single expression) to |\xintexpr round(<expression>, D)\relax|. @@ -17889,14 +17934,14 @@ Prime numbers are always cool x=10001..[2]..10200)\relax \end{everbatim*} -The syntax in this last example may look a bit involved (... and it is so I +The syntax in this last example may look a bit involved (...\@ and it is so I admit). First |x/:m| computes |x modulo m| (this is the modulo with respect to floored division). The |(x)?{yes}{no}| construct checks if |x| (which -\emph{must} be within parentheses) is true or false, i.e. non zero or zero. It +\emph{must} be within parentheses) is true or false, i.e.\@ non zero or zero. It then executes either the |yes| or the |no| branch, the non chosen branch is \emph{not} evaluated. Thus if |m| divides |x| we are in the second (``false'') branch. This gives a |-1|. This |-1| is the argument to a |??| branch which is -of the type |(y)??{y<0}{y=0}{y>0}|, thus here the |y<0|, i.e., |break(0)| is +of the type |(y)??{y<0}{y=0}{y>0}|, thus here the |y<0|, i.e.\@, |break(0)| is chosen. This |0| is thus given to another |?| which consequently chooses |omit|, hence the number is not kept in the list. The numbers which survive are the prime numbers. @@ -18080,7 +18125,7 @@ The input is still assumed positive. There is a deliberate blank before \csa{IsNotDivisibleBy} to use this feature of \csbxint{Apply}: a space stops the expansion of the applied macro (and disappears). This expansion will be done by \csbxint{ANDof}, which has been designed to skip everything as soon as it finds -a false (i.e. zero) input. This way, the efficiency is considerably improved. +a false (i.e.\@ zero) input. This way, the efficiency is considerably improved. We did generate via the \csbxint{Seq} too many potential divisors though. Later sections give two variants: one with \csbxint{iloop} (\autoref{ssec:primesII}) @@ -18787,7 +18832,7 @@ overhead in parsing fractions and scientific numbers as are acceptable by % values to List. The \oodef expands exactly twice (via a bunch of \expandafter's) \meaning\z \endgroup -\end{everbatim*} (the spaces after \string\d, etc... come from the use of the +\end{everbatim*} (the spaces after \string\d, etc...\@ come from the use of the |\meaning| primitive.) The choice of pivot as first element is bad if the list is already almost @@ -19629,7 +19674,7 @@ math shift catcode. \fi \XINT_providespackage \ProvidesPackage {xintkernel}% - [2021/06/11 v1.4i Paraphernalia for the xint packages (JFB)]% + [2021/07/13 v1.4j Paraphernalia for the xint packages (JFB)]% % \end{macrocode} % \subsection{Constants} % \begin{macrocode} @@ -20589,7 +20634,7 @@ mode) and will go ahead hoping repair\endcsname % \begin{macrocode} \XINT_providespackage \ProvidesPackage{xinttools}% - [2021/06/11 v1.4i Expandable and non-expandable utilities (JFB)]% + [2021/07/13 v1.4j Expandable and non-expandable utilities (JFB)]% % \end{macrocode} % \lverb|\XINT_toks is used in macros such as \xintFor. It is not used % elsewhere in the xint bundle.| @@ -21625,6 +21670,21 @@ mode) and will go ahead hoping repair\endcsname % \subsection{\csh{xintSeq}} % \lverb|1.09c. Without the optional argument puts stress on the input stack, % should not be used to generated thousands of terms then.| +% +% \changed{1.4j} +% This venerable macro had a brace removal bug in case it produced a single +% number: |\xintSeq{10}{10}| expanded to |10| not |{10}|. When I looked at the +% code the bug looked almost deliberate to me, but reading the documentation +% (which I have not modified), the behaviour is really unexpected. And the +% variant with step parameter |\xintSeq[1]{10}{10}| did produce |{10}|, so +% yes, definitely it was a bug! +% +% I take this occasion to do some style (and perhaps efficiency) refactoring +% in the coding. I feel there is room for improvement, no time this time. +% And I don't touch the variant with step parameter. +% +% Memo: \xintexprnameimp has some variants, a priori on ultra quick look +% they do not look like having similar bug as this one had. % \begin{macrocode} \def\xintSeq {\romannumeral0\xintseq }% \def\xintseq #1{\XINT_seq_chkopt #1\xint_bye }% @@ -21636,39 +21696,41 @@ mode) and will go ahead hoping repair\endcsname }% \def\XINT_seq_noopt #1\xint_bye #2% {% - \expandafter\XINT_seq\expandafter - {\the\numexpr#1\expandafter}\expandafter{\the\numexpr #2}% + \expandafter\XINT_seq + \the\numexpr#1\expandafter.\the\numexpr #2.% }% -\def\XINT_seq #1#2% +\def\XINT_seq #1.#2.% {% - \ifcase\ifnum #1=#2 0\else\ifnum #2>#1 1\else -1\fi\fi\space - \expandafter\xint_stop_atfirstoftwo - \or - \expandafter\XINT_seq_p - \else - \expandafter\XINT_seq_n - \fi - {#2}{#1}% + \ifnum #1=#2 \xint_dothis\XINT_seq_e\fi + \ifnum #2>#1 \xint_dothis\XINT_seq_pa\fi + \xint_orthat\XINT_seq_na + #2.{#1}{#2}% }% -\def\XINT_seq_p #1#2% +\def\XINT_seq_e#1.#2{}% +\def\XINT_seq_pa {\expandafter\XINT_seq_p\the\numexpr-\xint_c_i+}% +\def\XINT_seq_na {\expandafter\XINT_seq_n\the\numexpr\xint_c_i+}% +\def\XINT_seq_p #1.#2% {% \ifnum #1>#2 - \expandafter\expandafter\expandafter\XINT_seq_p + \expandafter\XINT_seq_p\the \else \expandafter\XINT_seq_e \fi - \expandafter{\the\numexpr #1-\xint_c_i}{#2}{#1}% + \numexpr #1-\xint_c_i.{#2}{#1}% }% -\def\XINT_seq_n #1#2% +\def\XINT_seq_n #1.#2% {% \ifnum #1<#2 - \expandafter\expandafter\expandafter\XINT_seq_n + \expandafter\XINT_seq_n\the \else \expandafter\XINT_seq_e \fi - \expandafter{\the\numexpr #1+\xint_c_i}{#2}{#1}% + \numexpr #1+\xint_c_i.{#2}{#1}% }% -\def\XINT_seq_e #1#2#3{ }% +% \end{macrocode} +% Note at time of the |1.4j| bug fix : I definitely should improve this branch +% and diminish the number of expandafter's but no time this time. +% \begin{macrocode} \def\XINT_seq_opt [\xint_bye #1]#2#3% {% \expandafter\XINT_seqo\expandafter @@ -22933,7 +22995,7 @@ mode) and will go ahead hoping repair\endcsname % \begin{macrocode} \XINT_providespackage \ProvidesPackage{xintcore}% - [2021/06/11 v1.4i Expandable arithmetic on big integers (JFB)]% + [2021/07/13 v1.4j Expandable arithmetic on big integers (JFB)]% % \end{macrocode} % \subsection{(WIP!) Error conditions and exceptions} % \lverb|As per the Mike Cowlishaw/IBM's General Decimal Arithmetic Specification @@ -26287,7 +26349,7 @@ mode) and will go ahead hoping repair\endcsname % \begin{macrocode} \XINT_providespackage \ProvidesPackage{xint}% - [2021/06/11 v1.4i Expandable operations on big integers (JFB)]% + [2021/07/13 v1.4j Expandable operations on big integers (JFB)]% % \end{macrocode} % \subsection{More token management} % \begin{macrocode} @@ -28866,7 +28928,7 @@ mode) and will go ahead hoping repair\endcsname % \begin{macrocode} \XINT_providespackage \ProvidesPackage{xintbinhex}% - [2021/06/11 v1.4i Expandable binary and hexadecimal conversions (JFB)]% + [2021/07/13 v1.4j Expandable binary and hexadecimal conversions (JFB)]% % \end{macrocode} % \subsection{Constants, etc...} % \lverb|1.2n switches to \csname-governed expansion at various places.| @@ -29538,7 +29600,7 @@ mode) and will go ahead hoping repair\endcsname % \begin{macrocode} \XINT_providespackage \ProvidesPackage{xintgcd}% - [2021/06/11 v1.4i Euclide algorithm with xint package (JFB)]% + [2021/07/13 v1.4j Euclide algorithm with xint package (JFB)]% % \end{macrocode} % \subsection{\csh{xintBezout}} % \lverb|& @@ -30138,7 +30200,7 @@ mode) and will go ahead hoping repair\endcsname % \begin{macrocode} \XINT_providespackage \ProvidesPackage{xintfrac}% - [2021/06/11 v1.4i Expandable operations on fractions (JFB)]% + [2021/07/13 v1.4j Expandable operations on fractions (JFB)]% % \end{macrocode} % \subsection{\csh{XINT_cntSgnFork}} % \lverb|1.09i. Used internally, #1 must expand to \m@ne, \z@, or \@ne or @@ -32971,7 +33033,7 @@ on input line \noexpand\the\inputlineno.&&J}}#2% % See comments for |\xintGCDof|. \xintnameimp provides the integer only % \csbxint{iiLCMof}. % -% \changes{1.4d}{} +% \changed{1.4d}{} % Sadly, although a public \xintfracnameimp macro, it did not (since |1.4|) % sanitize its arguments like other \xintfracnameimp macros. % @@ -35606,7 +35668,7 @@ on input line \noexpand\the\inputlineno.&&J}}#2% % \begin{macrocode} \XINT_providespackage \ProvidesPackage{xintseries}% - [2021/06/11 v1.4i Expandable partial sums with xint package (JFB)]% + [2021/07/13 v1.4j Expandable partial sums with xint package (JFB)]% % \end{macrocode} % \subsection{\csh{xintSeries}} % \begin{macrocode} @@ -36114,7 +36176,7 @@ on input line \noexpand\the\inputlineno.&&J}}#2% % \begin{macrocode} \XINT_providespackage \ProvidesPackage{xintcfrac}% - [2021/06/11 v1.4i Expandable continued fractions with xint package (JFB)]% + [2021/07/13 v1.4j Expandable continued fractions with xint package (JFB)]% % \end{macrocode} % \subsection{\csh{xintCFrac}} % \begin{macrocode} @@ -37507,7 +37569,7 @@ on input line \noexpand\the\inputlineno.&&J}}#2% % \begin{macrocode} \XINT_providespackage \ProvidesPackage{xintexpr}% - [2021/06/11 v1.4i Expandable expression parser (JFB)]% + [2021/07/13 v1.4j Expandable expression parser (JFB)]% \catcode`! 11 \let\XINT_Cmp \xintiiCmp \def\XINTfstop{\noexpand\XINTfstop}% @@ -38191,13 +38253,6 @@ on input line \noexpand\the\inputlineno.&&J}}#2% % The None is here handled as nil, i.e. it is unpacked, which is fine % as the documentations says nutples are unpacked. % -% This is somewhat complicated here due to the macro interfaces of -% \xintFirstOne, \xintLastOne and \xintLength which used a braced -% not a delimited argument, this forces here some re-grab which adds overhead. -% -% To avoid this one would like to move the check to inside {#2}, but then -% there is a difficulty caused by the nil (or None), if we apply a string -% technique as it will hit the closing brace. %| % \begin{macrocode} \def\XINT:NEhook:f:LFL #1{\expandafter#1\expandafter}% @@ -44532,10 +44587,10 @@ on input line \noexpand\the\inputlineno.&&J}}#2% \expandafter\xint_secondoftwo \fi {\immediate\write-1{Reloading xinttrig library using Digits=\xinttheDigits.}}% -{\expandafter\gdef\csname xintlibver@trig\endcsname{2021/06/11 v1.4i}% +{\expandafter\gdef\csname xintlibver@trig\endcsname{2021/07/13 v1.4j}% \XINT_providespackage \ProvidesPackage{xinttrig}% -[2021/06/11 v1.4i Trigonometrical functions for xintexpr (JFB)]% +[2021/07/13 v1.4j Trigonometrical functions for xintexpr (JFB)]% }% % \end{macrocode} % \subsection{Ensure used letters are dummy letters} @@ -45852,10 +45907,10 @@ on input line \noexpand\the\inputlineno.&&J}}#2% \expandafter\xint_secondoftwo \fi {\immediate\write-1{Reloading xintlog library using Digits=\xinttheDigits.}}% -{\expandafter\gdef\csname xintlibver@log\endcsname{2021/06/11 v1.4i}% +{\expandafter\gdef\csname xintlibver@log\endcsname{2021/07/13 v1.4j}% \XINT_providespackage \ProvidesPackage{xintlog}% -[2021/06/11 v1.4i Logarithms and exponentials for xintexpr (JFB)]% +[2021/07/13 v1.4j Logarithms and exponentials for xintexpr (JFB)]% }% % \end{macrocode} % \subsection{\csh{xintreloadxintlog}} @@ -45988,7 +46043,7 @@ on input line \noexpand\the\inputlineno.&&J}}#2% % my software. I was not expecting anyone to use it so I did back then in 2019 % a bit too expeditively the \xintExp thing on top of 10^x. % -% The 1.4e \PoorManExpr replaces and amends deceased \xintExp. +% The 1.4e \PoorManExp replaces and amends deceased \xintExp. % % Before using \xintRound we screen out the case of zero as \xintRound in this % case outputs no fractional digits. @@ -46237,7 +46292,7 @@ on input line \noexpand\the\inputlineno.&&J}}#2% % % 1.4e had the following bug (for Digits>8): big integer exponents used the % log10()/pow10() based approach rather than the legacy macro path which goes -% via \xintFloatPower, as done by \xintfloateval! As a result powers very +% via \xintFloatPower, as done by \xintfloateval! As a result powers with very % large integer exponents were more precise in \xintfloateval than in \xinteval! % % 1.4f fixes this. Also, it handles Digits<=8 as Digits>8, bringing much @@ -47942,8 +47997,8 @@ xinttrig.sty:64 \TeX\strut. Version {\xintbndlversion} of {\xintbndldate}.\par } -\CheckSum {38591}% 1.4i -% 38427 pour 1.4h +\CheckSum {38590}% 1.4j +% 38591 pour 1.4i, 38427 pour 1.4h % 38423 pour 1.4g, 38212 pour 1.4f, 38813 pour 1.4e, 35184 pour 1.4d % 35109 pour 1.4c, 35103 pour 1.4b, 34648 pour 1.4a, 34575 pour 1.4 % 33497 pour 1.3f, 33274 pour 1.3e, 31601 pour 1.3d, 31122 pour 1.3c diff --git a/Master/texmf-dist/tex/generic/xint/xint.sty b/Master/texmf-dist/tex/generic/xint/xint.sty index e200b4a03f5..01e0fb1b1a7 100644 --- a/Master/texmf-dist/tex/generic/xint/xint.sty +++ b/Master/texmf-dist/tex/generic/xint/xint.sty @@ -21,7 +21,7 @@ %% same distribution. (The sources need not necessarily be %% in the same archive or directory.) %% --------------------------------------------------------------- -%% The xint bundle 1.4i 2021/06/11 +%% The xint bundle 1.4j 2021/07/13 %% Copyright (C) 2013-2021 by Jean-Francois Burnol %% xint: Expandable operations on big integers %% --------------------------------------------------------------- @@ -70,7 +70,7 @@ \XINTsetupcatcodes% defined in xintkernel.sty (loaded by xintcore.sty) \XINT_providespackage \ProvidesPackage{xint}% - [2021/06/11 v1.4i Expandable operations on big integers (JFB)]% + [2021/07/13 v1.4j Expandable operations on big integers (JFB)]% \long\def\xint_firstofthree #1#2#3{#1}% \long\def\xint_secondofthree #1#2#3{#2}% \long\def\xint_thirdofthree #1#2#3{#3}% diff --git a/Master/texmf-dist/tex/generic/xint/xintbinhex.sty b/Master/texmf-dist/tex/generic/xint/xintbinhex.sty index 7a533988971..05ac782f8b1 100644 --- a/Master/texmf-dist/tex/generic/xint/xintbinhex.sty +++ b/Master/texmf-dist/tex/generic/xint/xintbinhex.sty @@ -21,7 +21,7 @@ %% same distribution. (The sources need not necessarily be %% in the same archive or directory.) %% --------------------------------------------------------------- -%% The xint bundle 1.4i 2021/06/11 +%% The xint bundle 1.4j 2021/07/13 %% Copyright (C) 2013-2021 by Jean-Francois Burnol %% xintbinhex: Expandable binary and hexadecimal conversions %% --------------------------------------------------------------- @@ -70,7 +70,7 @@ \XINTsetupcatcodes% defined in xintkernel.sty \XINT_providespackage \ProvidesPackage{xintbinhex}% - [2021/06/11 v1.4i Expandable binary and hexadecimal conversions (JFB)]% + [2021/07/13 v1.4j Expandable binary and hexadecimal conversions (JFB)]% \newcount\xint_c_ii^xv \xint_c_ii^xv 32768 \newcount\xint_c_ii^xvi \xint_c_ii^xvi 65536 \def\XINT_tmpa #1{\ifx\relax#1\else diff --git a/Master/texmf-dist/tex/generic/xint/xintcfrac.sty b/Master/texmf-dist/tex/generic/xint/xintcfrac.sty index d22b77d4c57..1893763130f 100644 --- a/Master/texmf-dist/tex/generic/xint/xintcfrac.sty +++ b/Master/texmf-dist/tex/generic/xint/xintcfrac.sty @@ -21,7 +21,7 @@ %% same distribution. (The sources need not necessarily be %% in the same archive or directory.) %% --------------------------------------------------------------- -%% The xint bundle 1.4i 2021/06/11 +%% The xint bundle 1.4j 2021/07/13 %% Copyright (C) 2013-2021 by Jean-Francois Burnol %% xintcfrac: Expandable continued fractions with xint package %% --------------------------------------------------------------- @@ -70,7 +70,7 @@ \XINTsetupcatcodes% defined in xintkernel.sty \XINT_providespackage \ProvidesPackage{xintcfrac}% - [2021/06/11 v1.4i Expandable continued fractions with xint package (JFB)]% + [2021/07/13 v1.4j Expandable continued fractions with xint package (JFB)]% \def\xintCFrac {\romannumeral0\xintcfrac }% \def\xintcfrac #1% {% diff --git a/Master/texmf-dist/tex/generic/xint/xintcore.sty b/Master/texmf-dist/tex/generic/xint/xintcore.sty index 8319611b1d8..982e345e6ea 100644 --- a/Master/texmf-dist/tex/generic/xint/xintcore.sty +++ b/Master/texmf-dist/tex/generic/xint/xintcore.sty @@ -21,7 +21,7 @@ %% same distribution. (The sources need not necessarily be %% in the same archive or directory.) %% --------------------------------------------------------------- -%% The xint bundle 1.4i 2021/06/11 +%% The xint bundle 1.4j 2021/07/13 %% Copyright (C) 2013-2021 by Jean-Francois Burnol %% xintcore: Expandable arithmetic on big integers %% --------------------------------------------------------------- @@ -70,7 +70,7 @@ \XINTsetupcatcodes% defined in xintkernel.sty \XINT_providespackage \ProvidesPackage{xintcore}% - [2021/06/11 v1.4i Expandable arithmetic on big integers (JFB)]% + [2021/07/13 v1.4j Expandable arithmetic on big integers (JFB)]% \csname XINT_Clamped_istrapped\endcsname \csname XINT_ConversionSyntax_istrapped\endcsname \csname XINT_DivisionByZero_istrapped\endcsname diff --git a/Master/texmf-dist/tex/generic/xint/xintexpr.sty b/Master/texmf-dist/tex/generic/xint/xintexpr.sty index 82f698d67ba..8f2f4e5ac61 100644 --- a/Master/texmf-dist/tex/generic/xint/xintexpr.sty +++ b/Master/texmf-dist/tex/generic/xint/xintexpr.sty @@ -21,7 +21,7 @@ %% same distribution. (The sources need not necessarily be %% in the same archive or directory.) %% --------------------------------------------------------------- -%% The xint bundle 1.4i 2021/06/11 +%% The xint bundle 1.4j 2021/07/13 %% Copyright (C) 2013-2021 by Jean-Francois Burnol %% xintexpr: Expandable expression parser %% --------------------------------------------------------------- @@ -82,7 +82,7 @@ \XINTsetupcatcodes% \XINT_providespackage \ProvidesPackage{xintexpr}% - [2021/06/11 v1.4i Expandable expression parser (JFB)]% + [2021/07/13 v1.4j Expandable expression parser (JFB)]% \catcode`! 11 \let\XINT_Cmp \xintiiCmp \def\XINTfstop{\noexpand\XINTfstop}% diff --git a/Master/texmf-dist/tex/generic/xint/xintfrac.sty b/Master/texmf-dist/tex/generic/xint/xintfrac.sty index e030a77b9ef..d5bb34ac647 100644 --- a/Master/texmf-dist/tex/generic/xint/xintfrac.sty +++ b/Master/texmf-dist/tex/generic/xint/xintfrac.sty @@ -21,7 +21,7 @@ %% same distribution. (The sources need not necessarily be %% in the same archive or directory.) %% --------------------------------------------------------------- -%% The xint bundle 1.4i 2021/06/11 +%% The xint bundle 1.4j 2021/07/13 %% Copyright (C) 2013-2021 by Jean-Francois Burnol %% xintfrac: Expandable operations on fractions %% --------------------------------------------------------------- @@ -70,7 +70,7 @@ \XINTsetupcatcodes% defined in xintkernel.sty \XINT_providespackage \ProvidesPackage{xintfrac}% - [2021/06/11 v1.4i Expandable operations on fractions (JFB)]% + [2021/07/13 v1.4j Expandable operations on fractions (JFB)]% \def\XINT_cntSgnFork #1% {% \ifcase #1\expandafter\xint_secondofthree diff --git a/Master/texmf-dist/tex/generic/xint/xintgcd.sty b/Master/texmf-dist/tex/generic/xint/xintgcd.sty index 7080a202df4..fc7051f3724 100644 --- a/Master/texmf-dist/tex/generic/xint/xintgcd.sty +++ b/Master/texmf-dist/tex/generic/xint/xintgcd.sty @@ -21,7 +21,7 @@ %% same distribution. (The sources need not necessarily be %% in the same archive or directory.) %% --------------------------------------------------------------- -%% The xint bundle 1.4i 2021/06/11 +%% The xint bundle 1.4j 2021/07/13 %% Copyright (C) 2013-2021 by Jean-Francois Burnol %% xintgcd: Euclidean algorithm with xint package %% --------------------------------------------------------------- @@ -77,7 +77,7 @@ \XINTsetupcatcodes% defined in xintkernel.sty \XINT_providespackage \ProvidesPackage{xintgcd}% - [2021/06/11 v1.4i Euclide algorithm with xint package (JFB)]% + [2021/07/13 v1.4j Euclide algorithm with xint package (JFB)]% \def\xintBezout {\romannumeral0\xintbezout }% \def\xintbezout #1% {% diff --git a/Master/texmf-dist/tex/generic/xint/xintkernel.sty b/Master/texmf-dist/tex/generic/xint/xintkernel.sty index 0f1bf0d3612..027c3b77562 100644 --- a/Master/texmf-dist/tex/generic/xint/xintkernel.sty +++ b/Master/texmf-dist/tex/generic/xint/xintkernel.sty @@ -21,7 +21,7 @@ %% same distribution. (The sources need not necessarily be %% in the same archive or directory.) %% --------------------------------------------------------------- -%% The xint bundle 1.4i 2021/06/11 +%% The xint bundle 1.4j 2021/07/13 %% Copyright (C) 2013-2021 by Jean-Francois Burnol %% xintkernel: Paraphernalia for the xint packages %% --------------------------------------------------------------- @@ -159,7 +159,7 @@ \fi \XINT_providespackage \ProvidesPackage {xintkernel}% - [2021/06/11 v1.4i Paraphernalia for the xint packages (JFB)]% + [2021/07/13 v1.4j Paraphernalia for the xint packages (JFB)]% \chardef\xint_c_ 0 \chardef\xint_c_i 1 \chardef\xint_c_ii 2 diff --git a/Master/texmf-dist/tex/generic/xint/xintlog.sty b/Master/texmf-dist/tex/generic/xint/xintlog.sty index 244607b847d..bc6d3039b08 100644 --- a/Master/texmf-dist/tex/generic/xint/xintlog.sty +++ b/Master/texmf-dist/tex/generic/xint/xintlog.sty @@ -21,7 +21,7 @@ %% same distribution. (The sources need not necessarily be %% in the same archive or directory.) %% --------------------------------------------------------------- -%% The xint bundle 1.4i 2021/06/11 +%% The xint bundle 1.4j 2021/07/13 %% Copyright (C) 2013-2021 by Jean-Francois Burnol %% xintlog: Logarithms and exponentials for xintexpr %% --------------------------------------------------------------- @@ -68,10 +68,10 @@ \expandafter\xint_secondoftwo \fi {\immediate\write-1{Reloading xintlog library using Digits=\xinttheDigits.}}% -{\expandafter\gdef\csname xintlibver@log\endcsname{2021/06/11 v1.4i}% +{\expandafter\gdef\csname xintlibver@log\endcsname{2021/07/13 v1.4j}% \XINT_providespackage \ProvidesPackage{xintlog}% -[2021/06/11 v1.4i Logarithms and exponentials for xintexpr (JFB)]% +[2021/07/13 v1.4j Logarithms and exponentials for xintexpr (JFB)]% }% \def\xintreloadxintlog{\input xintlog.sty }% \xintexprSafeCatcodes\catcode`_ 11 diff --git a/Master/texmf-dist/tex/generic/xint/xintseries.sty b/Master/texmf-dist/tex/generic/xint/xintseries.sty index 9946eb3bcbe..ad236f03790 100644 --- a/Master/texmf-dist/tex/generic/xint/xintseries.sty +++ b/Master/texmf-dist/tex/generic/xint/xintseries.sty @@ -21,7 +21,7 @@ %% same distribution. (The sources need not necessarily be %% in the same archive or directory.) %% --------------------------------------------------------------- -%% The xint bundle 1.4i 2021/06/11 +%% The xint bundle 1.4j 2021/07/13 %% Copyright (C) 2013-2021 by Jean-Francois Burnol %% xintseries: Expandable partial sums with xint package %% --------------------------------------------------------------- @@ -70,7 +70,7 @@ \XINTsetupcatcodes% defined in xintkernel.sty \XINT_providespackage \ProvidesPackage{xintseries}% - [2021/06/11 v1.4i Expandable partial sums with xint package (JFB)]% + [2021/07/13 v1.4j Expandable partial sums with xint package (JFB)]% \def\xintSeries {\romannumeral0\xintseries }% \def\xintseries #1#2% {% diff --git a/Master/texmf-dist/tex/generic/xint/xinttools.sty b/Master/texmf-dist/tex/generic/xint/xinttools.sty index 0faa20b0440..73a5f513892 100644 --- a/Master/texmf-dist/tex/generic/xint/xinttools.sty +++ b/Master/texmf-dist/tex/generic/xint/xinttools.sty @@ -21,7 +21,7 @@ %% same distribution. (The sources need not necessarily be %% in the same archive or directory.) %% --------------------------------------------------------------- -%% The xint bundle 1.4i 2021/06/11 +%% The xint bundle 1.4j 2021/07/13 %% Copyright (C) 2013-2021 by Jean-Francois Burnol %% xinttools: Expandable and non-expandable utilities %% --------------------------------------------------------------- @@ -70,7 +70,7 @@ \XINTsetupcatcodes% defined in xintkernel.sty \XINT_providespackage \ProvidesPackage{xinttools}% - [2021/06/11 v1.4i Expandable and non-expandable utilities (JFB)]% + [2021/07/13 v1.4j Expandable and non-expandable utilities (JFB)]% \newtoks\XINT_toks \xint_firstofone{\let\XINT_sptoken= } %<- space here! \def\xintgodef {\global\xintodef }% @@ -699,39 +699,37 @@ }% \def\XINT_seq_noopt #1\xint_bye #2% {% - \expandafter\XINT_seq\expandafter - {\the\numexpr#1\expandafter}\expandafter{\the\numexpr #2}% + \expandafter\XINT_seq + \the\numexpr#1\expandafter.\the\numexpr #2.% }% -\def\XINT_seq #1#2% +\def\XINT_seq #1.#2.% {% - \ifcase\ifnum #1=#2 0\else\ifnum #2>#1 1\else -1\fi\fi\space - \expandafter\xint_stop_atfirstoftwo - \or - \expandafter\XINT_seq_p - \else - \expandafter\XINT_seq_n - \fi - {#2}{#1}% + \ifnum #1=#2 \xint_dothis\XINT_seq_e\fi + \ifnum #2>#1 \xint_dothis\XINT_seq_pa\fi + \xint_orthat\XINT_seq_na + #2.{#1}{#2}% }% -\def\XINT_seq_p #1#2% +\def\XINT_seq_e#1.#2{}% +\def\XINT_seq_pa {\expandafter\XINT_seq_p\the\numexpr-\xint_c_i+}% +\def\XINT_seq_na {\expandafter\XINT_seq_n\the\numexpr\xint_c_i+}% +\def\XINT_seq_p #1.#2% {% \ifnum #1>#2 - \expandafter\expandafter\expandafter\XINT_seq_p + \expandafter\XINT_seq_p\the \else \expandafter\XINT_seq_e \fi - \expandafter{\the\numexpr #1-\xint_c_i}{#2}{#1}% + \numexpr #1-\xint_c_i.{#2}{#1}% }% -\def\XINT_seq_n #1#2% +\def\XINT_seq_n #1.#2% {% \ifnum #1<#2 - \expandafter\expandafter\expandafter\XINT_seq_n + \expandafter\XINT_seq_n\the \else \expandafter\XINT_seq_e \fi - \expandafter{\the\numexpr #1+\xint_c_i}{#2}{#1}% + \numexpr #1+\xint_c_i.{#2}{#1}% }% -\def\XINT_seq_e #1#2#3{ }% \def\XINT_seq_opt [\xint_bye #1]#2#3% {% \expandafter\XINT_seqo\expandafter diff --git a/Master/texmf-dist/tex/generic/xint/xinttrig.sty b/Master/texmf-dist/tex/generic/xint/xinttrig.sty index f1f6b44ea29..1269d48fca0 100644 --- a/Master/texmf-dist/tex/generic/xint/xinttrig.sty +++ b/Master/texmf-dist/tex/generic/xint/xinttrig.sty @@ -21,7 +21,7 @@ %% same distribution. (The sources need not necessarily be %% in the same archive or directory.) %% --------------------------------------------------------------- -%% The xint bundle 1.4i 2021/06/11 +%% The xint bundle 1.4j 2021/07/13 %% Copyright (C) 2013-2021 by Jean-Francois Burnol %% xinttrig: Trigonometry for the xintexpr package %% --------------------------------------------------------------- @@ -69,10 +69,10 @@ \expandafter\xint_secondoftwo \fi {\immediate\write-1{Reloading xinttrig library using Digits=\xinttheDigits.}}% -{\expandafter\gdef\csname xintlibver@trig\endcsname{2021/06/11 v1.4i}% +{\expandafter\gdef\csname xintlibver@trig\endcsname{2021/07/13 v1.4j}% \XINT_providespackage \ProvidesPackage{xinttrig}% -[2021/06/11 v1.4i Trigonometrical functions for xintexpr (JFB)]% +[2021/07/13 v1.4j Trigonometrical functions for xintexpr (JFB)]% }% \xintFor* #1 in {iDTVtuwxyzX}\do{\xintensuredummy{#1}}% \def\xintreloadxinttrig{\input xinttrig.sty }% |