diff options
author | Karl Berry <karl@freefriends.org> | 2023-08-21 20:21:43 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2023-08-21 20:21:43 +0000 |
commit | 387e312bc97ac7085a5303a50db5111a7e742a62 (patch) | |
tree | d20189887fd4cae8364ded2b6ad95dc924665dfb /Master/texmf-dist | |
parent | ab04753ec692a8080fca77d94a141f5e0fa0628d (diff) |
lualinalg (21aug23)
git-svn-id: svn://tug.org/texlive/trunk@68009 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist')
-rw-r--r-- | Master/texmf-dist/doc/lualatex/lualinalg/README.txt | 2 | ||||
-rw-r--r-- | Master/texmf-dist/doc/lualatex/lualinalg/lualinalg.pdf | bin | 270847 -> 268452 bytes | |||
-rw-r--r-- | Master/texmf-dist/doc/lualatex/lualinalg/lualinalg.tex | 8 | ||||
-rw-r--r-- | Master/texmf-dist/tex/lualatex/lualinalg/lualinalg.sty | 14 |
4 files changed, 8 insertions, 16 deletions
diff --git a/Master/texmf-dist/doc/lualatex/lualinalg/README.txt b/Master/texmf-dist/doc/lualatex/lualinalg/README.txt index 243edf9ccae..e63acad6718 100644 --- a/Master/texmf-dist/doc/lualatex/lualinalg/README.txt +++ b/Master/texmf-dist/doc/lualatex/lualinalg/README.txt @@ -1,5 +1,5 @@ # The lualinalg package -# version 1.6 +# version 1.7 # Authors: Chetan Shirore and Ajit Kumar # Email: mathsbeauty@gmail.com diff --git a/Master/texmf-dist/doc/lualatex/lualinalg/lualinalg.pdf b/Master/texmf-dist/doc/lualatex/lualinalg/lualinalg.pdf Binary files differindex 24f78d50525..30510d24908 100644 --- a/Master/texmf-dist/doc/lualatex/lualinalg/lualinalg.pdf +++ b/Master/texmf-dist/doc/lualatex/lualinalg/lualinalg.pdf diff --git a/Master/texmf-dist/doc/lualatex/lualinalg/lualinalg.tex b/Master/texmf-dist/doc/lualatex/lualinalg/lualinalg.tex index 250acd1544f..a5c792be1d5 100644 --- a/Master/texmf-dist/doc/lualatex/lualinalg/lualinalg.tex +++ b/Master/texmf-dist/doc/lualatex/lualinalg/lualinalg.tex @@ -1172,14 +1172,6 @@ The sum of squares of diagonal entries of matrix \(m = 98 + 54\mathrm{i}\). The sum of matrices \(m1,m2 \text{ and } m3 =\begin{bmatrix} 111 & 222 & 333 \\ 444 & 555 & 666+666\mathrm{i} \end{bmatrix} \). \end{framed} -\section{Known issues and limitations} -\begin{itemize} -\item The package supports small and big numbers. They can be input in the usual scientific notation. The math library in Lua defines constants with the maximum \verb|math.maxinteger| and the minimum \verb|math.mininteger| values for an integer. The result wraps around when there is a computational operation on integers that would result in a value smaller than the \verb|mininteger| or larger than the \verb|maxinteger|. It means that the computed result is the only number between the \verb|miniinteger| and \verb|maxinteger|. -\item The package currently supports only numerical computations. The table in a Lua is a data type that implements an associative array. This feature is used in packages to define and store vectors and matrices. This approach is close to object-oriented programming. It will allow easy conversion of algorithms in packages for symbolic computations. Future package updates will consider algorithm conversions to support symbolic calculations. - -\item The error handling mechanism in the tool is not robust. There are some custom errors included in the package. However the package mostly depends on error handling mechanism of Lua. The error handling can be strengthened in future updates of the package. - -\end{itemize} \end{document}
\ No newline at end of file diff --git a/Master/texmf-dist/tex/lualatex/lualinalg/lualinalg.sty b/Master/texmf-dist/tex/lualatex/lualinalg/lualinalg.sty index 5d3e502a8de..5c62f329fad 100644 --- a/Master/texmf-dist/tex/lualatex/lualinalg/lualinalg.sty +++ b/Master/texmf-dist/tex/lualatex/lualinalg/lualinalg.sty @@ -1,9 +1,9 @@ % The lualinalg package % Authors: Chetan Shirore and Ajit Kumar -% Version 1.6, Date=09-Aug-2023 +% Version 1.7, Date=21-Aug-2023 % Licensed under LaTeX Project Public License v1.3c or later. The complete license text is available at http://www.latex-project.org/lppl.txt. -\ProvidesPackage{lualinalg}[1.6] +\ProvidesPackage{lualinalg}[1.7] \RequirePackage{xkeyval} \RequirePackage{amsmath} \RequirePackage{luamaths} @@ -1132,7 +1132,7 @@ function vector.gs(inptTbl, brckt, dignum) local str = "" k = #inptTbl - if vector.euclidnorm(inptTbl[1]) ~= complex(0.0) then + if complex.round(vector.euclidnorm(inptTbl[1])) ~= complex("0.0") then tbl[1] = vector.mulnum(inptTbl[1], 1 / vector.euclidnorm(inptTbl[1])) else tbl[1] = vector.mulnum(inptTbl[1], 1) @@ -1146,7 +1146,7 @@ function vector.gs(inptTbl, brckt, dignum) setmetatable(tbl[j], vector_meta) tbl[i] = vector.sub(tbl[i], vector.mulnum(tbl[j], vector.dot(tbl[i], tbl[j]))) end - if vector.euclidnorm(tbl[i]) ~= complex(0.0) then + if complex.round(vector.euclidnorm(tbl[i])) ~= complex("0.0") then tbl[i] = vector.mulnum(tbl[i], 1 / vector.euclidnorm(tbl[i])) end tbl[i] = vector.mulnum(tbl[i], 1.0) @@ -1179,7 +1179,7 @@ function vector.gsX(inptTbl, brckt, dignum) k = #inptTbl str = str .. "\\ \\newline Take given vectors as $v_1,\\ldots, v_" .. k .. "$ in order." - if vector.euclidnorm(inptTbl[1]) ~= complex(0.0) then + if complex.round(vector.euclidnorm(inptTbl[1])) ~= complex("0.0") then tbl[1] = vector.mulnum(inptTbl[1], 1.0 / vector.euclidnorm(inptTbl[1])) else tbl[1] = vector.mulnum(inptTbl[1], 1.0) @@ -1188,7 +1188,7 @@ function vector.gsX(inptTbl, brckt, dignum) str = str .. "\\ \\newline Step " .. cnt .. ": $$ u_" .. cnt .. "=v_" .. cnt .. "=" str = str .. brcktL .. vector.show(inptTbl[1], dignum) .. brcktR str = str .. " $$ e_" .. cnt .. "=" - if vector.euclidnorm(tbl[1]) ~= complex(0.0) then + if complex.round(vector.euclidnorm(tbl[1])) ~= complex("0.0") then str = str .. "\\frac{u_{" .. cnt .. "}}" .. "{||u_{" .. cnt .. "}||} =" end str = str .. brcktL .. vector.show(tbl[1], dignum) .. brcktR @@ -1200,7 +1200,7 @@ function vector.gsX(inptTbl, brckt, dignum) tmpTbl[i] = vector.sub(tbl[i], vector.mulnum(tbl[j], vector.dot(tbl[i], tbl[j]))) tbl[i] = vector.sub(tbl[i], vector.mulnum(tbl[j], vector.dot(tbl[i], tbl[j]))) end - if vector.euclidnorm(tbl[i]) ~= complex(0.0) then + if complex.round(vector.euclidnorm(tbl[i])) ~= complex("0.0") then tbl[i] = vector.mulnum(tbl[i], 1 / vector.euclidnorm(tbl[i])) else tbl[i] = vector.mulnum(tbl[i], 1.0) |