C Linear Algebra

Open-source C projects categorized as Linear Algebra

Top 9 C Linear Algebra Projects

  • blis

    BLAS-like Library Instantiation Software Framework

  • Project mention: Optimize sgemm on RISC-V platform | news.ycombinator.com | 2024-02-28

    There is a recent update to the blis alternative to BLAS that includes a number of RISC-V performance optimizations.

    https://github.com/flame/blis/pull/737

  • arb

    Arb has been merged into FLINT -- use https://github.com/flintlib/flint/ instead

  • Project mention: Patriot Missile Floating point Software Problem lead to deaths 28 Americans | news.ycombinator.com | 2024-01-03

    You can instead list your criteria for good number format and look at alternatives with those lenses. Floating point is designed for a good balance between dynamic range and precision, and IEEE 754 binary formats can be seen as a FP standard particularly optimized for numerical calculation.

    There are several other FP formats. The most popular one is IEEE 754 minus subnormal numbers, followed by bfloat16, IEEE 754 decimal formats (formerly IEEE 854) and posits. Only first two have good hardware supports. The lack of subnormal number means that `a <=> b` can't be no longer rewritten to `a - b <=> 0` among others but is widely believed to be faster. (I don't fully agree, but it's indeed true for existing contemporary hardwares.) IEEE 754 decimal formats are notable for lack of normalization guarantee. Posits are, in some sense, what IEEE 754 would have been if designed today, and in fact aren't that fundamentally different from IEEE 754 in my opinion.

    Fixed-point formats share pros and cons of finitely sized integer numbers and you should have no difficulty to analyze them. In short, they offer a smaller dynamic range compared to FP, but its truncation model is much simpler to reason. In turn you will get a varying precision and out-of-bound issues.

    Rational number formats look very promising at the beginning, but they are much harder to implement efficiently. You will need a fast GCD algorithm (not Euclidean) and also have to handle out-of-bound numerators and denumerators. In fact, many rational number formats rely on arbitrary-precision integers precisely for avoiding those issues, and inherit the same set of issues---unbounded memory usage and computational overhead. Approximate rational number formats are much rarer, and I'm only aware of the Inigo Quilez's floating-bar experiment [1] in this space.

    [1] https://iquilezles.org/articles/floatingbar/

    Interval/ball/affine arithmetics and others are means to automatically approximate an error analysis. They have a good property of being never incorrect, but it is still really easy for them to throw up and give a correct but useless answer like [-inf, inf]. Also they are somewhat awkward in a typical procedural paradigm because comparisons will return a tri-state boolean (true, false, unsure). Nevertheless they are often useful when correctly used. Fredrik Johansson's Arb [2] is a good starting point in my opinion.

    [2] https://arblib.org/

    Finally you can model a number as a function that returns a successively accurate approximation. This is called the constructive or exact real number, and simultaneously most expensive and most correct. One of the most glaring problems is that an equality is not always decidable, and practical applications tend to have various heuristics to get around this fact. Amazingly enough, Android's built-in calculator is one of the most used applications that use this model [3].

    [3] https://dl.acm.org/doi/pdf/10.1145/2911981

  • WorkOS

    The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.

    WorkOS logo
  • numpower

    PHP library for efficient scientific computing and array manipulation with GPU support

  • Project mention: NumPower Was Recently Released for PHP | /r/learnmachinelearning | 2023-07-28

    Github: https://github.com/NumPower/numpower

  • neat-matrix-library

    nml is a "simple" matrix/numerical analysis library written in pure C. The scope of the library is to highlight various algorithm implementations related to matrices. Code readability was a major concern.

  • SuiteSparse

    SuiteSparse: a suite of sparse matrix packages by @DrTimothyAldenDavis et al. with native CMake support (by sergiud)

  • numruby

    Fast Numerical Linear Algebra Library for Ruby. NMatrix reimplementation.

  • Mathc

    A simple and clean, glsl like, math (linear algebra) header only library for C.

  • InfluxDB

    Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.

    InfluxDB logo
  • GLPK

    Mirror of GLPK versions and changes made by me and by others elsewhere

NOTE: The open source projects on this list are ordered by number of github stars. The number of mentions indicates repo mentiontions in the last 12 Months or since we started tracking (Dec 2020).

C Linear Algebra related posts

Index

What are some of the best open-source Linear Algebra projects in C? This list will help you:

Project Stars
1 blis 2,079
2 arb 455
3 numpower 146
4 neat-matrix-library 73
5 SuiteSparse 46
6 numruby 45
7 Mathc 15
8 GLPK 7
9 Code-Finds-Determinant-of-a-Array-in-C 1

Sponsored
SaaSHub - Software Alternatives and Reviews
SaaSHub helps you find the best software and product alternatives
www.saashub.com