{"repo":"konovod/linalg","free":true,"listed":false,"github":"https://github.com/konovod/linalg","clone":"git clone https://github.com/konovod/linalg.git","description":"Linear algebra library based on LAPACK","language":"Crystal","stars":53,"topics":["lapack","matrix","crystal","linear-algebra"],"license":"MIT","category":"chat-messaging","readme_excerpt":"linalg Linear algebra library in Crystal, uses LAPACK. - direct access to LAPACK methods - convenient Matrix(T) class, supports T=Float32, Float64 and Complex. - high-level interface similar to scipy.linalg or MATLAB. Killing SciPy, one module at a time. Installation 1. Install LAPACK and BLAS. sudo apt install libopenblas-base liblapack3 for Ubuntu, sudo pacman -S lapack (for better performance use openblas-lapack package from AUR) for Arch. For Windows you need libopenblas.dll (and libopenblas.lib) from https://github.com/xianyi/OpenBLAS/releases 2. (for Ubuntu 18) it seems package doesn't create symlink, so use - sudo ln -s /usr/lib/lapack/liblapack.so.3 /usr/lib/liblapack.so - sudo ln -s /usr/lib/openblas-base/libblas.so.3 /usr/lib/libcblas.so 3. Add this to your application's shard.yml : 4. Run shards install Usage Basic type aliases are - Mat = Matrix(Float64) - Mat32 = Matrix(Float32) - MatComplex = Matrix(Complex) Complex consisting of two Float32 isn't supported for now (it is easy, but I'm not sure if it's useful). Types with prefix G (GMat, GMat32, GMatComplex) are for actually allocated matrices, others are automatically converted to them when needed. other present features: - svd ( Mat#svd or Mat#svdvals for just values) - lu decomposition ( Mat#lu ) - matrix rank determination (using SVD or QRP) - linear least squares problem ( LA.solvels to just get decision or LA.lstsq to also get rank and singular values (TODO - and residues)) - cholesky decomposition ( #chol","default_branch":null,"files":null,"tree":[],"storefront":"/r/konovod","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/konovod/linalg/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}