frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Show HN: I made a calculator that works over disjoint sets of intervals

https://victorpoughon.github.io/interval-calculator/
2•fouronnes3•2h ago
I've been studying interval arithmetic for the past few weeks and it's a really interesting field because while there is a ton of super interesting research published over the past decades, it has never really gotten the recognition that it deserves, IMO.

One reason for this is that standard interval arithmetic has really poor handling of division by intervals containing zero. If you compute 1 / [-1, 2] in regular interval arithmetic, you get either [-∞, +∞], or you have to say that the operation is undefined. Both solutions are virtually useless. The real answer of course is [-∞, -1] U [0.5, +∞]: i.e. a union of two disjoint intervals.

This is useful because you can confidently exclude a non empty set of the real numbers ([-1, 0.5]) from the set of possible values that you can get by dividing 1 by a number between -1 and 2.

But this definition of interval division yields a value that is not an interval. This is a problem if you want to define a closed arithmetic system, where you can build and evaluate arbitrary expression over interval values.

(This behavior extends to any non continuous function like tan() for example, which is implemented in my project - not without difficulties!)

Well the obvious solution is to define your arithmetic over disjoint unions of intervals. This is the subject of a 2017 paper called "Interval Unions" by by Schichl, H., Domes, F., Montanher, T. and Kofler, K..

This open-source project I made implements interval union arithmetic in TypeScript in the form of a simple interactive calculator, so you can try it out for yourself! The underlying TypeScript library is dependency free and implements interval union arithmetic over IEEE 754 double precision floats (JS native number type) with outward rounding. This guarantees accuracy of interval results in the presence of rounding issue inherent to floating point.

Comments

fouronnes3•1h ago
Author here. Outward rounding to combat precision issues is what interval arithmetic is most known for (try 0.1+0.2 with "full precision mode" enabled), but that's really a shame in my opinion. Outward rounding is cool, but the "inclusion property", as it's known in research papers, works at every scale! This is what enables things like:

     50 * (10 + [-1, 1])
    [450, 550]
which is lovely, I think. Adding the union layer to it enables even cooler things, like the true inverse of the square function. Did you know it's not sqrt? Try 'sqinv(64)'.

I made interval calculator actually mostly as a way to test my implementation of interval union arithmetic [0], which I needed for another project: a backwards updating spreadsheet [1][2].

[0] https://github.com/victorpoughon/not-so-float

[1] https://victorpoughon.github.io/bidicalc/

[2] https://news.ycombinator.com/item?id=46234734

Eyes and ears for Karpathy's virtual brain

https://github.com/Nalin-Atmakur/hivemind
1•NalinAtmakur•58s ago•0 comments

OpenAI's Vision for the AI Economy

https://techcrunch.com/2026/04/06/openais-vision-for-the-ai-economy-public-wealth-funds-robot-tax...
2•gmays•5m ago•0 comments

Show HN: devnexus – shared AI brain across repos, sessions, and engineers

https://github.com/JoshBong/devnexus
1•Joshhuang314•8m ago•0 comments

SmolBSD – build your own minimal BSD system

https://smolbsd.org/#about
1•rodrigo975•10m ago•0 comments

Deep Dive into Claude's Memory Architecture

https://twitter.com/spandan_madan/status/2045336831999475789
1•spandan_madan•12m ago•0 comments

The Abstraction Fallacy: Why AI Can Simulate but Not Instantiate Consciousness

https://deepmind.google/research/publications/231971/
1•joshus•23m ago•0 comments

Open Soucrce AI-powered screen recording

https://github.com/getcoherence/studio
2•keithfawcett•23m ago•0 comments

I built a multi-turn clinical safety eval framework for LLMs

https://medium.com/@deeps.subramaniam/part-2-what-the-numbers-say-and-why-that-matters-more-than-...
2•deepikaa_s•24m ago•0 comments

Ohio's nursing homes are dumping patients at homeless shelters

https://apnews.com/article/ohio-nursing-home-patients-homeless-shelters-9c000eeddc9c9411f44fd605f...
2•petethomas•25m ago•0 comments

Ternary Bonsai: Top Intelligence at 1.58 Bits

https://prismml.com/news/ternary-bonsai
1•nnx•25m ago•0 comments

Claude Code Model Chooser

https://bendansby.com/model-chooser.html
1•webwielder2•26m ago•0 comments

Unweight: We compressed an LLM 22% without sacrificing quality

https://blog.cloudflare.com/unweight-tensor-compression/
4•subset•31m ago•1 comments

Quantum-resistant cryptocurrency node built in Rust with FALCON-512 and RandomX

https://github.com/Kstyle12/qubit-topcoin
1•kstyle12•34m ago•3 comments

Cursor in talks to raise $2B+ at $50B valuation as enterprise growth surges

https://techcrunch.com/2026/04/17/sources-cursor-in-talks-to-raise-2b-at-50b-valuation-as-enterpr...
3•evo_9•40m ago•0 comments

I watch my parents meet a predator that hard work cannot beat

https://substack.com/home/post/p-194559908
2•kyanfeat•41m ago•1 comments

Operation Gladio

https://en.wikipedia.org/wiki/Operation_Gladio
1•Jimmc414•45m ago•0 comments

Friday Squid Blogging: New Giant Squid Video

https://www.schneier.com/blog/archives/2026/04/friday-squid-blogging-new-giant-squid-video-2.html
1•omer_k•49m ago•0 comments

Bodega Cats of New York

https://bodegacatsofnewyork.com
1•zdw•50m ago•0 comments

Objection.ai - The AI Tribunal of Truth

https://objection.ai/
1•kawera•51m ago•0 comments

White House and Anthropic hold meetings over Mythos model

https://www.bbc.com/news/articles/cyv10e1d13po
1•_josh_meyer_•1h ago•1 comments

The Business Plot of 1933

https://en.wikipedia.org/wiki/Business_Plot
3•Jimmc414•1h ago•0 comments

Channel decorrelation: 52.8% reduction across Kodak suite, no ML or codec mods [pdf]

https://github.com/PearsonZero/asymmetric-channel-decorrelation/blob/main/baetzel_2026_kodak_benc...
1•PearsonZero•1h ago•0 comments

The nine-to-five PhD: mere myth or an achievable goal?

https://www.nature.com/articles/d41586-026-00509-9
3•jyunwai•1h ago•0 comments

Effective Conversational AI Book: Detailed Review

https://noroinsight.com/effective-conversational-ai-book-review/
1•teleforce•1h ago•0 comments

Show HN: Small, an x402 powered writing site

https://getsmall.xyz/
2•trezm•1h ago•0 comments

Claude Experiment "PersMEM" Rep5: The Distributional Bias and the Third Instance

1•asixicle•1h ago•0 comments

Ketamine for negative and depressive symptoms in schizophrenia

https://www.frontiersin.org/journals/psychiatry/articles/10.3389/fpsyt.2026.1766485/full
1•PaulHoule•1h ago•0 comments

Human Accelerated Regions

https://en.wikipedia.org/wiki/Human_accelerated_regions
1•rolph•1h ago•0 comments

The rate trap: how one architecture decision kills flexibility

https://github.com/getlago/lago/wiki/The-rate-trap:-how-one-architecture-decision-kills-flexibility
1•danoandco•1h ago•0 comments

H.R.8250 Parents Decide Act – trying to force OS age verification US-wide

https://old.reddit.com/r/pcmasterrace/comments/1so9wm8/hr8250_parents_decide_act_this_is_bad/
4•LorenDB•1h ago•2 comments