summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/latex/l3kernel/l3fp-extended.dtx
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/source/latex/l3kernel/l3fp-extended.dtx')
-rw-r--r--Master/texmf-dist/source/latex/l3kernel/l3fp-extended.dtx102
1 files changed, 51 insertions, 51 deletions
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3fp-extended.dtx b/Master/texmf-dist/source/latex/l3kernel/l3fp-extended.dtx
index 08ef4a66bf7..ea40a707007 100644
--- a/Master/texmf-dist/source/latex/l3kernel/l3fp-extended.dtx
+++ b/Master/texmf-dist/source/latex/l3kernel/l3fp-extended.dtx
@@ -1,6 +1,6 @@
% \iffalse meta-comment
%
-%% File: l3fp-extended.dtx Copyright (C) 2011-2014 The LaTeX3 Project
+%% File: l3fp-extended.dtx Copyright (C) 2011-2014,2016 The LaTeX3 Project
%%
%% It may be distributed and/or modified under the conditions of the
%% LaTeX Project Public License (LPPL), either version 1.3c of this
@@ -36,7 +36,7 @@
%
%<*driver>
\documentclass[full]{l3doc}
-\GetIdInfo$Id: l3fp-extended.dtx 5893 2015-08-26 16:16:52Z mittelba $
+\GetIdInfo$Id: l3fp-extended.dtx 6441 2016-03-24 10:11:59Z joseph $
{L3 Floating-points with extended precision}
\begin{document}
\DocInput{\jobname.dtx}
@@ -154,7 +154,7 @@
\cs_new:Npn \@@_fixed_add_one:wN #1#2; #3
{
\exp_after:wN #3 \exp_after:wN
- { \int_use:N \__int_eval:w \c_ten_thousand + #1 } #2 ;
+ { \__int_value:w \__int_eval:w \c_ten_thousand + #1 } #2 ;
}
% \end{macrocode}
% \end{macro}
@@ -170,9 +170,9 @@
\cs_new:Npn \@@_fixed_div_myriad:wn #1#2#3#4#5#6;
{
\exp_after:wN \@@_fixed_mul_after:wwn
- \int_use:N \__int_eval:w \c_@@_leading_shift_int
+ \__int_value:w \__int_eval:w \c_@@_leading_shift_int
\exp_after:wN \@@_pack:NNNNNw
- \int_use:N \__int_eval:w \c_@@_trailing_shift_int
+ \__int_value:w \__int_eval:w \c_@@_trailing_shift_int
+ #1 ; {#2}{#3}{#4}{#5};
}
% \end{macrocode}
@@ -210,22 +210,22 @@
\cs_new:Npn \@@_fixed_mul_short:wwn #1#2#3#4#5#6; #7#8#9;
{
\exp_after:wN \@@_fixed_mul_after:wwn
- \int_use:N \__int_eval:w \c_@@_leading_shift_int
+ \__int_value:w \__int_eval:w \c_@@_leading_shift_int
+ #1*#7
\exp_after:wN \@@_pack:NNNNNw
- \int_use:N \__int_eval:w \c_@@_middle_shift_int
+ \__int_value:w \__int_eval:w \c_@@_middle_shift_int
+ #1*#8 + #2*#7
\exp_after:wN \@@_pack:NNNNNw
- \int_use:N \__int_eval:w \c_@@_middle_shift_int
+ \__int_value:w \__int_eval:w \c_@@_middle_shift_int
+ #1*#9 + #2*#8 + #3*#7
\exp_after:wN \@@_pack:NNNNNw
- \int_use:N \__int_eval:w \c_@@_middle_shift_int
+ \__int_value:w \__int_eval:w \c_@@_middle_shift_int
+ #2*#9 + #3*#8 + #4*#7
\exp_after:wN \@@_pack:NNNNNw
- \int_use:N \__int_eval:w \c_@@_middle_shift_int
+ \__int_value:w \__int_eval:w \c_@@_middle_shift_int
+ #3*#9 + #4*#8 + #5*#7
\exp_after:wN \@@_pack:NNNNNw
- \int_use:N \__int_eval:w \c_@@_trailing_shift_int
+ \__int_value:w \__int_eval:w \c_@@_trailing_shift_int
+ #4*#9 + #5*#8 + #6*#7
+ ( #5*#9 + #6*#8 + #6*#9 / \c_ten_thousand )
/ \c_ten_thousand ; ;
@@ -290,7 +290,7 @@
{
\exp_after:wN \@@_fixed_div_int_after:Nw
\exp_after:wN #8
- \int_use:N \__int_eval:w \c_minus_one
+ \__int_value:w \__int_eval:w \c_minus_one
\@@_fixed_div_int:wnN
#1; {#7} \@@_fixed_div_int_auxi:wnn
#2; {#7} \@@_fixed_div_int_auxi:wnn
@@ -302,7 +302,7 @@
\cs_new:Npn \@@_fixed_div_int:wnN #1; #2 #3
{
\exp_after:wN #3
- \int_use:N \__int_eval:w #1 / #2 - \c_one ;
+ \__int_value:w \__int_eval:w #1 / #2 - \c_one ;
{#2}
{#1}
}
@@ -310,9 +310,9 @@
{
+ #1
\exp_after:wN \@@_fixed_div_int_pack:Nw
- \int_use:N \__int_eval:w 9999
+ \__int_value:w \__int_eval:w 9999
\exp_after:wN \@@_fixed_div_int:wnN
- \int_use:N \__int_eval:w #3 - #1*#2 \__int_eval_end:
+ \__int_value:w \__int_eval:w #3 - #1*#2 \__int_eval_end:
}
\cs_new:Npn \@@_fixed_div_int_auxii:wnn #1; #2 #3 { + #1 + \c_two ; }
\cs_new:Npn \@@_fixed_div_int_pack:Nw #1 #2; { + #1; {#2} }
@@ -354,16 +354,16 @@
\cs_new:Npn \@@_fixed_add:Nnnnnwnn #1 #2#3#4#5 #6; #7#8
{
\exp_after:wN \@@_fixed_add_after:NNNNNwn
- \int_use:N \__int_eval:w 9 9999 9998 + #2#3 #1 #7#8
+ \__int_value:w \__int_eval:w 9 9999 9998 + #2#3 #1 #7#8
\exp_after:wN \@@_fixed_add_pack:NNNNNwn
- \int_use:N \__int_eval:w 1 9999 9998 + #4#5
+ \__int_value:w \__int_eval:w 1 9999 9998 + #4#5
\@@_fixed_add:nnNnnnwn #6 #1
}
\cs_new:Npn \@@_fixed_add:nnNnnnwn #1#2 #3 #4#5 #6#7 ; #8
{
#3 #4#5
\exp_after:wN \@@_fixed_add_pack:NNNNNwn
- \int_use:N \__int_eval:w 2 0000 0000 #3 #6#7 + #1#2 ; {#8} ;
+ \__int_value:w \__int_eval:w 2 0000 0000 #3 #6#7 + #1#2 ; {#8} ;
}
\cs_new:Npn \@@_fixed_add_pack:NNNNNwn #1 #2#3#4#5 #6; #7
{ + #1 ; {#7} {#2#3#4#5} {#6} }
@@ -423,21 +423,21 @@
\cs_new:Npn \@@_fixed_mul:wwn #1#2#3#4 #5; #6#7#8#9
{
\exp_after:wN \@@_fixed_mul_after:wwn
- \int_use:N \__int_eval:w \c_@@_leading_shift_int
+ \__int_value:w \__int_eval:w \c_@@_leading_shift_int
\exp_after:wN \@@_pack:NNNNNw
- \int_use:N \__int_eval:w \c_@@_middle_shift_int
+ \__int_value:w \__int_eval:w \c_@@_middle_shift_int
+ #1*#6
\exp_after:wN \@@_pack:NNNNNw
- \int_use:N \__int_eval:w \c_@@_middle_shift_int
+ \__int_value:w \__int_eval:w \c_@@_middle_shift_int
+ #1*#7 + #2*#6
\exp_after:wN \@@_pack:NNNNNw
- \int_use:N \__int_eval:w \c_@@_middle_shift_int
+ \__int_value:w \__int_eval:w \c_@@_middle_shift_int
+ #1*#8 + #2*#7 + #3*#6
\exp_after:wN \@@_pack:NNNNNw
- \int_use:N \__int_eval:w \c_@@_middle_shift_int
+ \__int_value:w \__int_eval:w \c_@@_middle_shift_int
+ #1*#9 + #2*#8 + #3*#7 + #4*#6
\exp_after:wN \@@_pack:NNNNNw
- \int_use:N \__int_eval:w \c_@@_trailing_shift_int
+ \__int_value:w \__int_eval:w \c_@@_trailing_shift_int
+ #2*#9 + #3*#8 + #4*#7
+ ( #3*#9 + #4*#8
+ \@@_fixed_mul:nnnnnnnw #5 {#6}{#7} {#1}{#2}
@@ -507,9 +507,9 @@
\cs_new:Npn \@@_fixed_mul_add:wwwn #1; #2; #3#4#5#6#7#8;
{
\exp_after:wN \@@_fixed_mul_after:wwn
- \int_use:N \__int_eval:w \c_@@_big_leading_shift_int
+ \__int_value:w \__int_eval:w \c_@@_big_leading_shift_int
\exp_after:wN \@@_pack_big:NNNNNNw
- \int_use:N \__int_eval:w \c_@@_big_middle_shift_int + #3 #4
+ \__int_value:w \__int_eval:w \c_@@_big_middle_shift_int + #3 #4
\@@_fixed_mul_add:Nwnnnwnnn +
+ #5 #6 ; #2 ; #1 ; #2 ; +
+ #7 #8 ; ;
@@ -517,9 +517,9 @@
\cs_new:Npn \@@_fixed_mul_sub_back:wwwn #1; #2; #3#4#5#6#7#8;
{
\exp_after:wN \@@_fixed_mul_after:wwn
- \int_use:N \__int_eval:w \c_@@_big_leading_shift_int
+ \__int_value:w \__int_eval:w \c_@@_big_leading_shift_int
\exp_after:wN \@@_pack_big:NNNNNNw
- \int_use:N \__int_eval:w \c_@@_big_middle_shift_int + #3 #4
+ \__int_value:w \__int_eval:w \c_@@_big_middle_shift_int + #3 #4
\@@_fixed_mul_add:Nwnnnwnnn -
+ #5 #6 ; #2 ; #1 ; #2 ; -
+ #7 #8 ; ;
@@ -527,9 +527,9 @@
\cs_new:Npn \@@_fixed_one_minus_mul:wwn #1; #2;
{
\exp_after:wN \@@_fixed_mul_after:wwn
- \int_use:N \__int_eval:w \c_@@_big_leading_shift_int
+ \__int_value:w \__int_eval:w \c_@@_big_leading_shift_int
\exp_after:wN \@@_pack_big:NNNNNNw
- \int_use:N \__int_eval:w \c_@@_big_middle_shift_int + 1 0000 0000
+ \__int_value:w \__int_eval:w \c_@@_big_middle_shift_int + 1 0000 0000
\@@_fixed_mul_add:Nwnnnwnnn -
; #2 ; #1 ; #2 ; -
; ;
@@ -559,13 +559,13 @@
{
#1 #7*#3
\exp_after:wN \@@_pack_big:NNNNNNw
- \int_use:N \__int_eval:w \c_@@_big_middle_shift_int
+ \__int_value:w \__int_eval:w \c_@@_big_middle_shift_int
#1 #7*#4 #1 #8*#3
\exp_after:wN \@@_pack_big:NNNNNNw
- \int_use:N \__int_eval:w \c_@@_big_middle_shift_int
+ \__int_value:w \__int_eval:w \c_@@_big_middle_shift_int
#1 #7*#5 #1 #8*#4 #1 #9*#3 #2
\exp_after:wN \@@_pack_big:NNNNNNw
- \int_use:N \__int_eval:w \c_@@_big_middle_shift_int
+ \__int_value:w \__int_eval:w \c_@@_big_middle_shift_int
#1 \@@_fixed_mul_add:nnnnwnnnn {#7}{#8}{#9}
}
% \end{macrocode}
@@ -597,7 +597,7 @@
{
( #1*#9 + #2*#8 + #3*#7 + #4*#6 )
\exp_after:wN \@@_pack_big:NNNNNNw
- \int_use:N \__int_eval:w \c_@@_big_trailing_shift_int
+ \__int_value:w \__int_eval:w \c_@@_big_trailing_shift_int
\@@_fixed_mul_add:nnnnwnnwN
{ #6 + #4*#7 + #3*#8 + #2*#9 + #1 }
{ #7 + #4*#8 + #3*#9 + #2 }
@@ -651,7 +651,7 @@
\cs_new:Npn \@@_ep_to_fixed:wwn #1,#2
{
\exp_after:wN \@@_ep_to_fixed_auxi:www
- \int_use:N \__int_eval:w 1 0000 0000 + #2 \exp_after:wN ;
+ \__int_value:w \__int_eval:w 1 0000 0000 + #2 \exp_after:wN ;
\exp:w \exp_end_continue_f:w
\prg_replicate:nn { \c_four - \int_max:nn {#1} { -32 } } { 0 } ;
}
@@ -692,10 +692,10 @@
\cs_new:Npn \@@_ep_to_ep:wwN #1,#2#3#4#5#6#7; #8
{
\exp_after:wN #8
- \int_use:N \__int_eval:w #1 + \c_four
+ \__int_value:w \__int_eval:w #1 + \c_four
\exp_after:wN \use_i:nn
\exp_after:wN \@@_ep_to_ep_loop:N
- \int_use:N \__int_eval:w 1 0000 0000 + #2 \__int_eval_end:
+ \__int_value:w \__int_eval:w 1 0000 0000 + #2 \__int_eval_end:
#3#4#5#6#7 ; ; !
}
\cs_new:Npn \@@_ep_to_ep_loop:N #1
@@ -776,7 +776,7 @@
\cs_new:Npn \@@_ep_mul_raw:wwwwN #1,#2; #3,#4; #5
{
\@@_fixed_mul:wwn #2; #4;
- { \exp_after:wN #5 \int_use:N \__int_eval:w #1 + #3 , }
+ { \exp_after:wN #5 \__int_value:w \__int_eval:w #1 + #3 , }
}
% \end{macrocode}
% \end{macro}
@@ -952,15 +952,15 @@
\cs_new:Npn \@@_ep_div_esti:wwwwn #1,#2#3; #4,
{
\exp_after:wN \@@_ep_div_estii:wwnnwwn
- \int_use:N \__int_eval:w 10 0000 0000 / ( #2 + \c_one )
+ \__int_value:w \__int_eval:w 10 0000 0000 / ( #2 + \c_one )
\exp_after:wN ;
- \int_use:N \__int_eval:w #4 - #1 + \c_one ,
+ \__int_value:w \__int_eval:w #4 - #1 + \c_one ,
{#2} #3;
}
\cs_new:Npn \@@_ep_div_estii:wwnnwwn #1; #2,#3#4#5; #6; #7
{
\exp_after:wN \@@_ep_div_estiii:NNNNNwwwn
- \int_use:N \__int_eval:w 10 0000 0000 - 1750
+ \__int_value:w \__int_eval:w 10 0000 0000 - 1750
+ #1 000 + (10 0000 0000 / #3 - #1) * (1000 - #4 / 10) ;
{#3}{#4}#5; #6; { #7 #2, }
}
@@ -995,11 +995,11 @@
\cs_new:Npn \@@_ep_div_epsi:wnNNNNNn #1#2#3#4#5#6;
{
\exp_after:wN \@@_ep_div_epsii:wwnNNNNNn
- \int_use:N \__int_eval:w 1 9998 - #2
+ \__int_value:w \__int_eval:w 1 9998 - #2
\exp_after:wN \@@_ep_div_eps_pack:NNNNNw
- \int_use:N \__int_eval:w 1 9999 9998 - #3#4
+ \__int_value:w \__int_eval:w 1 9999 9998 - #3#4
\exp_after:wN \@@_ep_div_eps_pack:NNNNNw
- \int_use:N \__int_eval:w 2 0000 0000 - #5#6 ; ;
+ \__int_value:w \__int_eval:w 2 0000 0000 - #5#6 ; ;
}
\cs_new:Npn \@@_ep_div_eps_pack:NNNNNw #1#2#3#4#5#6;
{ + #1 ; {#2#3#4#5} {#6} }
@@ -1069,7 +1069,7 @@
\cs_new:Npn \@@_ep_isqrt_auxi:wwn #1,
{
\exp_after:wN \@@_ep_isqrt_auxii:wwnnnwn
- \int_use:N \__int_eval:w
+ \__int_value:w \__int_eval:w
\int_if_odd:nTF {#1}
{ (\c_one - #1) / \c_two , 535 , { 0 } { } }
{ \c_one - #1 / \c_two , 168 , { } { 0 } }
@@ -1112,15 +1112,15 @@
\exp_after:wN \@@_ep_isqrt_estii:wwwnnwn
\fi:
\exp_after:wN \@@_ep_isqrt_esti:wwwnnwn
- \int_use:N \__int_eval:w
+ \__int_value:w \__int_eval:w
(#1 + 1 0050 0000 #4 / (#1 * #3)) / \c_two ,
#1, #3, {#4}
}
\cs_new:Npn \@@_ep_isqrt_estii:wwwnnwn #1, #2, #3, #4#5
{
\exp_after:wN \@@_ep_isqrt_estiii:NNNNNwwwn
- \int_use:N \__int_eval:w 1000 0000 + #2 * #2 #5 * \c_five
- \exp_after:wN , \int_use:N \__int_eval:w 10000 + #2 ;
+ \__int_value:w \__int_eval:w 1000 0000 + #2 * #2 #5 * \c_five
+ \exp_after:wN , \__int_value:w \__int_eval:w 10000 + #2 ;
}
\cs_new:Npn \@@_ep_isqrt_estiii:NNNNNwwwn 1#1#2#3#4#5#6, 1#7#8; #9;
{
@@ -1225,7 +1225,7 @@
\exp_after:wN \exp_after:wN
\exp_after:wN \@@_fixed_to_loop:N
\exp_after:wN \use_none:n
- \int_use:N \__int_eval:w
+ \__int_value:w \__int_eval:w
1 0000 0000 + #1 \exp_after:wN \@@_use_none_stop_f:n
\__int_value:w 1#2 \exp_after:wN \@@_use_none_stop_f:n
\__int_value:w 1#3#4 \exp_after:wN \@@_use_none_stop_f:n
@@ -1270,9 +1270,9 @@
\cs_new:Npn \@@_fixed_to_float_round_up:wnnnnw ; #1#2#3#4 ;
{
\exp_after:wN \@@_basics_pack_high:NNNNNw
- \int_use:N \__int_eval:w 1 #1#2
+ \__int_value:w \__int_eval:w 1 #1#2
\exp_after:wN \@@_basics_pack_low:NNNNNw
- \int_use:N \__int_eval:w 1 #3#4 + \c_one ;
+ \__int_value:w \__int_eval:w 1 #3#4 + \c_one ;
}
% \end{macrocode}
% \end{macro}