summaryrefslogtreecommitdiff
path: root/macros/generic
diff options
context:
space:
mode:
Diffstat (limited to 'macros/generic')
-rw-r--r--macros/generic/polexpr/README.md5
-rw-r--r--macros/generic/polexpr/polexpr.html9
-rw-r--r--macros/generic/polexpr/polexpr.sty2
-rw-r--r--macros/generic/polexpr/polexprcore.tex2
-rw-r--r--macros/generic/polexpr/polexprexpr.tex2
-rw-r--r--macros/generic/polexpr/polexprsturm.tex31
6 files changed, 31 insertions, 20 deletions
diff --git a/macros/generic/polexpr/README.md b/macros/generic/polexpr/README.md
index 8e99584aed..de201582d3 100644
--- a/macros/generic/polexpr/README.md
+++ b/macros/generic/polexpr/README.md
@@ -89,8 +89,11 @@ Releases
Track `xintexpr` 1.4e changes
- 0.8.3 (2021/05/27)
Track `xintexpr` 1.4h changes
+- 0.8.4 (2021/11/01)
+ Bugfix: `PolSturmIsolateZeros**` did not declare the square free
+ part of the original polynomial if no real root existed.
-Files of 0.8.3 release:
+Files of 0.8.4 release:
- polexpr.sty, polexprcore.tex, polexprexpr.tex, polexprsturm.tex,
- README.md,
diff --git a/macros/generic/polexpr/polexpr.html b/macros/generic/polexpr/polexpr.html
index cc6e722926..3fdb584ea8 100644
--- a/macros/generic/polexpr/polexpr.html
+++ b/macros/generic/polexpr/polexpr.html
@@ -598,7 +598,7 @@ a { text-decoration: none; }
<body>
<div class="document" id="package-polexpr-documentation">
<h1 class="title">Package polexpr documentation</h1>
-<p class="subtitle" id="id1">0.8.3 (2021/05/27)</p>
+<p class="subtitle" id="id1">0.8.4 (2021/11/01)</p>
<div class="contents topic" id="contents">
<p class="topic-title">Contents</p>
@@ -4197,6 +4197,13 @@ regarding handling of exceptions. Will require this version at
least on loading.</p></li>
</ul>
</li>
+<li><p>v0.8.4 (2021/11/01)</p>
+<ul class="simple">
+<li><p>bugfix: <a class="reference internal" href="#id17">\PolSturmIsolateZeros**{&lt;sturmname&gt;}</a> did not
+declare the <span class="docutils literal">&lt;sturmname&gt;_norr</span> and <span class="docutils literal">&lt;sturmname&gt;_sqf_norr</span>
+polynomials if original polynomial had no real root!</p></li>
+</ul>
+</li>
</ul>
</div>
<div class="section" id="acknowledgments">
diff --git a/macros/generic/polexpr/polexpr.sty b/macros/generic/polexpr/polexpr.sty
index c92f950adb..a2334e9724 100644
--- a/macros/generic/polexpr/polexpr.sty
+++ b/macros/generic/polexpr/polexpr.sty
@@ -2,7 +2,7 @@
% License: LPPL 1.3c (author-maintained)
% Usage: \input polexpr.sty (Plain or other macro formats)
% or \usepackage{polexpr} (LaTeX macro format)
-% Release 0.8.3 (2021/05/27) of polexpr.sty. This file inputs
+% Release 0.8.4 (2021/11/01) of polexpr.sty. This file inputs
% polexprcore.tex
% polexprexpr.tex
% polexprsturm.tex
diff --git a/macros/generic/polexpr/polexprcore.tex b/macros/generic/polexpr/polexprcore.tex
index d8a17e4fc2..3315790b95 100644
--- a/macros/generic/polexpr/polexprcore.tex
+++ b/macros/generic/polexpr/polexprcore.tex
@@ -1,4 +1,4 @@
-%% This file polexprcore.tex is part of the polexpr package (0.8.3, 2021/05/27)
+%% This file polexprcore.tex is part of the polexpr package (0.8.4, 2021/11/01)
%% Core routines to match infix operators +, -, *, //, /:, ^, ** and some
%% functions
%% The atoms representing polynomials inside \xintexpr are
diff --git a/macros/generic/polexpr/polexprexpr.tex b/macros/generic/polexpr/polexprexpr.tex
index 8e025db1c7..d896e4b39b 100644
--- a/macros/generic/polexpr/polexprexpr.tex
+++ b/macros/generic/polexpr/polexprexpr.tex
@@ -1,4 +1,4 @@
-%% This file polexprexpr.tex is part of the polexpr package (0.8.3, 2021/05/27)
+%% This file polexprexpr.tex is part of the polexpr package (0.8.4, 2021/11/01)
%% Extending \xintexpr syntax:
%%
%% 1. Authorize ' in variable and function names
diff --git a/macros/generic/polexpr/polexprsturm.tex b/macros/generic/polexpr/polexprsturm.tex
index f2ac7c0d17..317b9cbcd3 100644
--- a/macros/generic/polexpr/polexprsturm.tex
+++ b/macros/generic/polexpr/polexprsturm.tex
@@ -1,4 +1,4 @@
-%% This file polexprsturm.tex is part of the polexpr package (0.8.3, 2021/05/27)
+%% This file polexprsturm.tex is part of the polexpr package (0.8.4, 2021/11/01)
%% Sturm Algorithm (polexpr 0.4)
%% 0.5 uses primitive polynomials for faster evaluations afterwards
%% 0.6 corrects misuse of \@ifstar! (mumble). \PolToSturm* was broken.
@@ -196,17 +196,7 @@
\edef\POL@sturm@N{\@nameuse{PolSturmChainLength_\POL@sturmname}}%
% isolate the roots (detects case of constant polynomial)
\PolSturmIsolateZeros@{\POL@sturmname}%
- \ifnum\POL@isolz@NbOfRoots=\z@
- % no real roots, define empty arrays nevertheless
- \begingroup\globaldefs\@ne
- \expandafter\xintAssignArray\expandafter\to\csname POL_ZM\POL@sturmname*\endcsname
- \expandafter\xintAssignArray\expandafter\to\csname POL_RI\POL@sturmname*\endcsname
- \endgroup
- \else
- % all we currently know is that multiplicities are at least one
- \begingroup\globaldefs\@ne
- \expandafter\POL@initarray\csname POL_ZM\POL@sturmname*\endcsname{1}%
- \endgroup
+ % 0.8.4 fix: these declarations were formerly not executed in absence of roots!
% on ne va pas utiliser de Horner, mais des divisions par X - x, et ces
% choses vont évoluer, ainsi que le coefficient dominant entier
% (pour \POL@divide entre autres if faut des noms de user pol)
@@ -218,6 +208,17 @@
\expandafter\let
\csname POLuserpol@\POL@sturmname\POL@norr\expandafter\endcsname
\csname POLuserpol@\POL@sturmname _0_\endcsname
+ \ifnum\POL@isolz@NbOfRoots=\z@
+ % no real roots, define empty arrays nevertheless
+ \begingroup\globaldefs\@ne
+ \expandafter\xintAssignArray\expandafter\to\csname POL_ZM\POL@sturmname*\endcsname
+ \expandafter\xintAssignArray\expandafter\to\csname POL_RI\POL@sturmname*\endcsname
+ \endgroup
+ \else
+ % all we currently know is that multiplicities are at least one
+ \begingroup\globaldefs\@ne
+ \expandafter\POL@initarray\csname POL_ZM\POL@sturmname*\endcsname{1}%
+ \endgroup
% attention formé avec\xintREZ d'où le \xintAbs pas \xintiiAbs
% D and its exponent E will get updated along the way
\edef\POL@findrat@D{\xintAbs{\PolLeadingCoeff{\POL@sturmname _0}}}%
@@ -243,12 +244,12 @@
\def\POL@findrat@index{1}%
\POL@findrat@loop@secondpass
\fi
- % declare the new polynomials
- \POL@newpol{\POL@sturmname\POL@sqfnorr}% without multiplicities
- \POL@newpol{\POL@sturmname\POL@norr}% with multiplicities
% declare the array holding the interval indices for the rational roots
\expandafter\POL@findrat@doRRarray\csname POL_RI\POL@sturmname*\endcsname
\fi
+ % declare the new polynomials (also if no real roots exist)
+ \POL@newpol{\POL@sturmname\POL@sqfnorr}% without multiplicities
+ \POL@newpol{\POL@sturmname\POL@norr}% with multiplicities
}%
\def\POL@findrat@doRRarray#1{%
% il faudrait un \xintAssignArray* qui fasse même expansion que \xintFor*