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. Learn more →
Top 23 floating-point Open-Source Projects
-
number-precision
🚀1K tiny & fast lib for doing addition, subtraction, multiplication and division operations precisely
-
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.
-
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.
-
Kraken
Kraken is an open-source modern math library that comes with a fast-fixed matrix class and math-related functions. (by yahya-mohammed07)
-
SaaSHub
SaaSHub - Software Alternatives and Reviews. SaaSHub helps you find the best software and product alternatives
Continuation passing monads form the basis of a perfectly valid and usable software architecture and programming pattern.
In the case of ostream and operator<<, this pattern reduces the number of intermediate objects that would otherwise be constructed.
If you object to iostream on religious or stylistic grounds, there's always fmt which is more like Go or Python string interpolation.[0]
0. https://fmt.dev
Project mention: mpmath – Python library for arbitrary-precision floating-point arithmetic | news.ycombinator.com | 2024-01-19
Project mention: Show HN: Time Series Benchmark TurboPFor,TurboFloat,TurboFloat LzX,TurboGorilla | news.ycombinator.com | 2023-06-25
Project mention: Herbie: Find and fix floating-point accuracy problems | news.ycombinator.com | 2023-11-28
Project mention: Patriot Missile Floating point Software Problem lead to deaths 28 Americans | news.ycombinator.com | 2024-01-03You 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
Project mention: FloatCompMandelbrot: What impact does floating point precision have on Mandelbr | news.ycombinator.com | 2024-03-12Seems like this algorithm does not do that ?
https://github.com/ProfJski/FloatCompMandelbrot/blob/master/...
> [...] Instead, we put pixels in a one-to-one relation to the points they represent. You can think of this as mapping some imaginary point on the pixel, such as its center or corner, onto the complex plane, and making the whole pixel represent that value.
There was a really awful and amazing floating point implementation posted here¹ a couple of years ago, with a few interesting comments too². I remember it in part because I was surprised there wasn't more discussion.
¹ https://github.com/clarity20/shellmath
² https://news.ycombinator.com/item?id=26250743
floating-point related posts
- FloatCompMandelbrot: What impact does floating point precision have on Mandelbr
- Minimum Volume Ellipsoid
- mpmath – Python library for arbitrary-precision floating-point arithmetic
- Herbie: Find and fix floating-point accuracy problems
- Lies My Calculator and Computer Told Me [pdf]
- Towards a New SymPy
-
mpmath VS gmpy - a user suggested alternative
2 projects | 2 Aug 2023
-
A note from our sponsor - InfluxDB
www.influxdata.com | 26 Apr 2024
Index
What are some of the best open-source floating-point projects? This list will help you:
Project | Stars | |
---|---|---|
1 | C++ Format | 19,307 |
2 | number-precision | 3,982 |
3 | mpmath | 906 |
4 | TurboPFor | 743 |
5 | herbie | 720 |
6 | arb | 455 |
7 | robust-predicates | 285 |
8 | rust-lexical | 279 |
9 | fast-float-rust | 266 |
10 | FastDoubleParser | 165 |
11 | soft-float-starter-pack | 157 |
12 | approx | 145 |
13 | DoubleFloats.jl | 144 |
14 | Drachennest | 111 |
15 | FloatCompMandelbrot | 104 |
16 | verificarlo | 61 |
17 | verrou | 44 |
18 | PERCIVAL | 40 |
19 | vpu-count | 40 |
20 | big decimal | 38 |
21 | shellmath | 34 |
22 | Kraken | 29 |
23 | decimal | 28 |
Sponsored