I am happy to announce a new project: lna (Lua Numerical Algorithms). lna is a Lua library that provides support for matrices, linear algebra, complex numbers, optimization algorithms, ODE solver, PCA / LDA, FFT, and other numerical algorithms for Lua.
The objective is to incentive scientific computing in Lua. It does not (yet) compares to numpy/scipy for Python, but already provides the essentials (such as efficient linear algebra operations).
Linear algebra operations such as computing the eigenvalues/vectors, matrix inversion, solving a linear system, among others, are done with lapack, while other algorithms are implemented in Lua itself.
Strictly speaking, lna it is not a Lua library, but a pure LuaJIT library since it depends on LuaJIT FFI to use lapack routines. Due to LuaJIT, the operations that are performed in Lua are roughly as fast as the ones implemented in native code. One does not need to vectorize its implementation to achieve good performance, i.e., unlike Python+numpy, you can actually loop element-by-element of a matrix and still achieve good performance.
lna is licensed under the same license as Lua (MIT) and has been implemented primary with correctness in mind (then performance and easy of use). In the git repository you will find a test suit, examples, and complete documentation of the library.
lna is still a very young project, so it may contain bugs. Every contribution (patch, ideas, bug report) is welcome.