frontpage.
newsnewestaskshowjobs

Open Source @Github

fp.

Open in hackernews

A calculator that doesn't round

https://constructive-calculator.dimview.org/writeup.html
26•dimview•3d ago

Comments

dimview•3d ago
Author here. I could not find a constructive‑reals calculator on iPhone, so I ported the engine Android uses: Hans Boehm's com.hp.creals plus AOSP's UnifiedReal/BoundedRational. Used Opus 4.8 to do the port and Fable 5 for the review.

Fable 5 caught a couple of real concurrency bugs the port introduced while adapting Java's synchronized/AsyncTask to Swift concurrency, including one that was a memory‑safety bug on shared singletons like π, not just a wrong digit. None would have shown up in the unit tests. Writeup has the details.

It's an early iPhone TestFlight beta (link in the post); happy to go deep on either the constructive‑reals side or the AI‑assisted‑dev side.

nomel•1h ago
The old HP calculators, and their emulators, have a computer algebra system, for symbolic maths, that supported this. The user interfaces leave much to be desired, but some also have reverse Polish notation!
NetMageSCW•38m ago
Maybe you should correct the errors in your post before worrying about the code.
jagraff•1h ago
Very interesting, thank you for posting! I'm curious - roughly how many tokens do you think you used during the initial port and subsequent bug hunting and fixes?
piinbinary•1h ago
It would also be fun to have a full computer algebra system (like maxima) on a phone
Jblx2•1h ago
Edit: Whoops. My bad. This must have been a HN "second chance" winner.
ColinWright•51m ago
Er, that's this submission.
badc0ffee•51m ago
That looks like a link right back to this thread?
htx80nerd•1h ago
btw if you turn the iphone calc into landscape mode and switch you scientific calc it does Ramanujan's constant without rounding, but stops after the twelve 9s.
__alexs•1h ago
> Hans Boehm built a Java library for this in the 1980s and 90s

Hans is such a prolific programmer that he wrote a Java library before Java was even invented?

tomjakubowski•1h ago
The article has so many of the hallmarks of LLM writing, naturally it will have some hallucinated factoids too. "What that gives you: [bullet list]", "What got ported: [bullet list]", "foo: x, y, just z"

Boehm's Java library has copyright dates of 1999 and 2001-2004. https://www.hboehm.info/new_crcalc/CR.java

The whitepaper was only published in 2005: https://www.sciencedirect.com/science/article/pii/S156783260...

I have a dimview now of the blog, and of this Swift port of the library, indeed.

nxobject•36m ago
Well, you know, you go into your Smalltalk-80 workstation for a hack sesh, and an all-nighter later you end up with an implementatkon of Swing...
quixoticelixer-•50m ago
I don't get why this is a big deal. All the calculators I've used have been rectangle.
bla3•40m ago
> I built one, by porting Boehm’s engine. > It’s 2026, so I didn’t hand-write the port. I directed Opus 4.8 to translate the source line by line into Swift

I wish I could filter out stuff like this. Cool work by Hans Boehm, but what's the value add in this blog post.

A backdoor in a LinkedIn job offer

https://roman.pt/posts/linkedin-backdoor/
454•lwhsiao•3h ago•88 comments

US battery manufacturing output continues to break records

https://fred.stlouisfed.org/series/IPG33591S
104•epistasis•2h ago•74 comments

Iroh 1.0

https://www.iroh.computer/blog/v1
850•chadfowler•7h ago•267 comments

I Love the Computer

https://michaelenger.com/blog/i-love-the-computer/
87•speckx•2h ago•54 comments

TinyWind: A pixel pirate sailing game with real wind physics (380k+ kms sailed)

https://tinywind.io
527•tinywind•6h ago•108 comments

Swedish parliament abolishes permanent residence visas for migrants

https://www.riksdagen.se/en/news/articles/2026/jun/9/permanent-residence-permits-to-be-abolished_...
26•CGMthrowaway•41m ago•34 comments

Ask HN: Has anyone replaced Claude/GPT with a local model for daily coding?

561•cloudking•8h ago•285 comments

Banned Book Library in a Wi-Fi Smart Light Bulb

https://www.richardosgood.com/posts/banned-book-library/
12•sohkamyung•27m ago•0 comments

The Dead Economy Theory

https://gmalandrakis.com/writings/ad-economicum.html
34•l0new0lf-G•1h ago•35 comments

Why I Email Complete Strangers

https://www.goodinternetmagazine.com/why-i-email-complete-strangers/
23•karakoram•1h ago•7 comments

My Homelab AI Dev Platform

https://rsgm.dev/post/ai-dev-platform/
202•rsgm•7h ago•42 comments

What job interviews taught me about Kubernetes

https://notnotp.com/notes/what-job-interviews-taught-me-about-kubernetes/
29•chmaynard•2h ago•17 comments

Game Engine White Papers Commander Keen

https://forgottenbytes.net/commander_keen.html
123•mfiguiere•5h ago•42 comments

Hetzner Price Adjustment

https://docs.hetzner.com/general/infrastructure-and-availability/price-adjustment/#cloud-servers
287•tuhtah•9h ago•420 comments

How TimescaleDB compresses time-series data

https://roszigit.com/en/blog/timescaledb-compression-hypercore
101•lkanwoqwp•5h ago•14 comments

What every coder should know about Gamma Correction

https://blog.johnnovak.net/2016/09/21/what-every-coder-should-know-about-gamma/
29•sph•2d ago•13 comments

Launch HN: Drafted (YC P26) – Models for residential architecture

33•PrimalNick•6h ago•47 comments

Factoring "short-sleeve" RSA keys with polynomials

https://blog.trailofbits.com/2026/06/12/factoring-short-sleeve-rsa-keys-with-polynomials/
62•ledoge•3d ago•1 comments

Fox to buy Roku

https://www.wsj.com/business/deals/fox-roku-deal-f6e564f9
246•thm•10h ago•348 comments

Commander Keen Games (free book)

https://forgottenbytes.net/
16•tzury•2h ago•3 comments

Show HN: Vet turned founder, AI lawn diagnosis

https://grassdx.com/
26•andrewbr•5h ago•17 comments

Show HN: Fata – Spaced repetition to fight skill rot from AI coding

https://fata.dev
67•djoume•4d ago•41 comments

Copper transport drug restores memory and clears toxic Alzheimer's proteins

https://www.monash.edu/news/articles/copper-drug-restores-memory-and-clears-toxic-alzheimers-prot...
222•bookofjoe•8h ago•86 comments

Making glass-to-metal seals for home­made vacuum tubes

https://maurycyz.com/projects/glass/1/
116•zdw•1d ago•36 comments

How memory safety CVEs differ between Rust and C/C++

https://kobzol.github.io/rust/2026/06/15/how-memory-safety-cves-differ-between-rust-and-c-cpp.html
95•nicoburns•6h ago•90 comments

Boot Naked Linux

https://nick.zoic.org/art/boot-naked-linux/
76•abnercoimbre•7h ago•43 comments

Reviving an abandoned open-source project: 6 years of Atomic Calendar Revive

https://totaldebug.uk/posts/reviving-an-abandoned-open-source-project/
7•marksie1988•2d ago•1 comments

Typst 0.15.0

https://typst.app/docs/changelog/0.15.0/
246•schu•5h ago•68 comments

Techno-libertarians are flocking to the Caribbean

https://economist.com/the-americas/2026/06/11/techno-libertarians-are-flocking-to-the-caribbean
34•andsoitis•1h ago•34 comments

San Francisco Weighs PG&E Takeover Amid Soaring Utility Costs

https://www.kqed.org/news/12081882/san-francisco-has-been-trying-to-leave-pge-for-100-years-will-...
17•cdrnsf•1h ago•7 comments