diff options
author | Karl Berry <karl@freefriends.org> | 2019-09-11 21:20:03 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2019-09-11 21:20:03 +0000 |
commit | ae7f7ce522ff387f85698d8f28692b008de1e520 (patch) | |
tree | a4d84570bc7d03d1fa854e9cb3d9878da7bc0101 /Master/texmf-dist/tex/generic/poormanlog | |
parent | b294a44f24410094addc2c6d6cc4a17471bb567e (diff) |
poormanlog (11sep19)
git-svn-id: svn://tug.org/texlive/trunk@52080 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/generic/poormanlog')
-rw-r--r-- | Master/texmf-dist/tex/generic/poormanlog/poormanlog.sty | 4 | ||||
-rw-r--r-- | Master/texmf-dist/tex/generic/poormanlog/poormanlog.tex | 142 |
2 files changed, 4 insertions, 142 deletions
diff --git a/Master/texmf-dist/tex/generic/poormanlog/poormanlog.sty b/Master/texmf-dist/tex/generic/poormanlog/poormanlog.sty index c740360e985..e164999faa1 100644 --- a/Master/texmf-dist/tex/generic/poormanlog/poormanlog.sty +++ b/Master/texmf-dist/tex/generic/poormanlog/poormanlog.sty @@ -1,4 +1,4 @@ -%% poormanlog.sty v0.04, 2019/02/17 +%% poormanlog.sty v0.05, 2019/04/22 %% %% Copyright (C) 2019, Jean-Francois Burnol %% @@ -12,6 +12,6 @@ %% This Work consists of files poormanlog.tex, poormanlog.sty and %% the accompanying README %% -\ProvidesPackage{poormanlog}[2019/02/17 v0.04 log and powers with 9 digits (JFB)] +\ProvidesPackage{poormanlog}[2019/04/22 v0.05 base 10 log and pow with 9 digits (JFB)] \input{poormanlog.tex}% see README file for user documentation \endinput diff --git a/Master/texmf-dist/tex/generic/poormanlog/poormanlog.tex b/Master/texmf-dist/tex/generic/poormanlog/poormanlog.tex index e29c2089010..f1faa665479 100644 --- a/Master/texmf-dist/tex/generic/poormanlog/poormanlog.tex +++ b/Master/texmf-dist/tex/generic/poormanlog/poormanlog.tex @@ -1,4 +1,4 @@ -%% poormanlog.tex v0.04, 2019/02/17 +%% poormanlog.tex v0.05, 2019/04/22 %% %% Copyright (C) 2019, Jean-Francois Burnol %% @@ -12,11 +12,6 @@ %% This Work consists of files poormanlog.tex, poormanlog.sty and the %% README %% -%% ************ BARELY TESTED **************** -%% >>>>>>> WARNING FOR LACK OF TIME I HAVE NOT YET VALIDATED FULLY <<<<< -%% >>>>>>> NOR HAVE I MADE PRECISE ESTIMATES. USE AT YOUR OWN RISK <<<<< -%% (bug reports welcome) -%% ************ BARELY TESTED **************** % % Package macro private prefix: \PML@ % @@ -35,7 +30,7 @@ \catcode`\noexpand\^ \the\catcode`\^ % \catcode`\noexpand\: \the\catcode`\: % \catcode`\noexpand\* \the\catcode`\* % - \catcode`\noexpand\@ \the\catcode`\@ % + \catcode`\noexpand\@ \the\catcode`\@\relax }% \catcode`\@ 11 % \if1\ifx\@namedef\JFBUundefined1\else\ifx\@namedef\relax1\else0\fi\fi @@ -284,138 +279,5 @@ \the\numexpr1000000000+\expandafter\PML@\romannumeral-`0#1.\relax }% \def\PMPowTen#1{\the\numexpr\expandafter\PML@Pa\romannumeral-`0#1.\relax}% -%% -%% -%% ADD-ONS TO XINTFRAC : \PoorManLogBaseTen{#1}, \PoorManPowerOfTen{#1} -%% and \PoorManPower{#1}{#2} -%% Does not matter if xintfrac loaded before or after. -%% -\def\PoorManLogBaseTen{\romannumeral0\poormanlogbaseten}% -\def\poormanlogbaseten #1% - {\expandafter\PML@logbaseten\romannumeral0\XINTinfloat[9]{#1}}% -\def\PML@logbaseten#1[#2]% -{% - \xintiiadd{\xintDSx{-9}{\the\numexpr#2+8\relax}}{\the\numexpr\PML@#1.}% - [-9]% -}% -% -\def\PoorManPowerOfTen{\the\numexpr\poormanpoweroften}% -\def\poormanpoweroften #1% - {\expandafter\PML@powoften\romannumeral0\xintraw{#1}}% -\catcode`\_ 11 % -\def\PML@powoften#1{% - \xint_UDzerominusfork - #1-\PML@powoften@zero - 0#1\PML@powoften@neg - 0-\PML@powoften@pos - \krof #1% -}% -\catcode`\_ 8 % -\def\PML@powoften@zero 0{1\relax}%/1[0] -\def\PML@powoften@pos#1[#2]{% - \expandafter\PML@powoften@pos@a\romannumeral0\xintround{9}{#1[#2]}.% -}% -\def\PML@powoften@pos@a#1.#2.{\PML@Pa#2.\expandafter[\the\numexpr-8+#1]}% -\def\PML@powoften@neg#1[#2]{% - \expandafter\PML@powoften@neg@a\romannumeral0\xintround{9}{#1[#2]}.% -}% -\def\PML@powoften@neg@a#1.#2.{\ifnum#2=0 \xint_afterfi{1\relax/1[#1]}\else - \expandafter\expandafter\expandafter - \PML@Pa\expandafter\@gobble\the\numexpr2000000000-#2.% - \expandafter[\the\numexpr-9+#1\expandafter]\fi -}% -% -\def\PoorManPower#1#2% #1**#2 -{% - \PoorManPowerOfTen{\xintMul{#2}{\PoorManLogBaseTen{#1}}}% -}% -%% -%% ADD-ONS TO XINTEXPR : -%% -%% log10(), pow10() -%% -%% Does not matter if xintexpr loaded before or after. -%% -\catcode`\_ 11 \catcode`\: 11 % -\unless\ifcsname XINT_expr_func_log10\endcsname -\@namedef{XINT_expr_func_log10}#1#2#3% -{% - \expandafter #1\expandafter #2\csname.=% - \XINT:NEhook:one\PoorManLogBaseTen{\XINT_expr_unlock #3}\endcsname -}% -\fi -\unless\ifcsname XINT_flexpr_func_log10\endcsname -\expandafter\let\csname XINT_flexpr_func_log10\expandafter\endcsname - \csname XINT_expr_func_log10\endcsname -\fi -% -\unless\ifcsname XINT_expr_func_pow10\endcsname -\@namedef{XINT_expr_func_pow10}#1#2#3% -{% - \expandafter #1\expandafter #2\csname.=% - \XINT:NEhook:one\PoorManPowerOfTen{\XINT_expr_unlock #3}\endcsname -}% -\fi -\unless\ifcsname XINT_flexpr_func_pow10\endcsname -\expandafter\let\csname XINT_flexpr_func_pow10\expandafter\endcsname - \csname XINT_expr_func_pow10\endcsname -\fi -%% -%% On-demand modification of ** or ^ operators in \xintexpr and \xintfloatexpr -%% -\catcode`\* 11 \catcode0 12 % -% -\def\poormanloghack**{% -\def\XINT_expr_op_** ##1% -{% - \expandafter \XINT_expr_until_**_a - \expandafter ##1\romannumeral`^^@\expandafter\XINT_expr_getnext -}% -\def\XINT_expr_until_**_a ##1{% -\def\XINT_expr_until_**_a ####1####2% -{% - \xint_UDsignfork - ####2{\expandafter \XINT_expr_until_**_a \expandafter ##1% - \romannumeral`^^@##1}% - -{\XINT_expr_until_**_b ####1####2}% - \krof -}}\expandafter\XINT_expr_until_**_a\csname XINT_expr_op_-ix\endcsname -\def\XINT_expr_until_**_b ##1##2##3##4% -{% - \ifnum ##2>\XINT_expr_precedence_** - \xint_afterfi - {\expandafter \XINT_expr_until_**_a \expandafter ##1% - \romannumeral`^^@\csname XINT_expr_op_##3\endcsname {##4}}% - \else - \xint_afterfi - {\expandafter ##2\expandafter ##3% - \csname .=\XINT:NEhook:two - \PoorManPower{\XINT_expr_unlock ##1}{\XINT_expr_unlock ##4}\endcsname - }% - \fi -}% -\let\XINT_flexpr_op_** \XINT_expr_op_** -\let\XINT_flexpr_until_**_a\XINT_expr_until_**_a -\let\XINT_flexpr_until_**_b\XINT_expr_until_**_b -}% -\catcode`\^ 11 \catcode`\* 7 % -\def\poormanloghack^{% -\def\XINT_expr_until_^_b ##1##2##3##4% -{% - \ifnum ##2>\XINT_expr_precedence_^ - \xint_afterfi - {\expandafter \XINT_expr_until_^_a \expandafter ##1% - \romannumeral`**@\csname XINT_expr_op_##3\endcsname {##4}}% - \else - \xint_afterfi - {\expandafter ##2\expandafter ##3% - \csname .=\XINT:NEhook:two - \PoorManPower{\XINT_expr_unlock ##1}{\XINT_expr_unlock ##4}\endcsname - }% - \fi -}% -\let\XINT_flexpr_until_^_b\XINT_expr_until_^_b -}% \@tempa -\def\poormanloghack#1{\csname poormanloghack#1\endcsname}% \endinput |