News for hackers. Stuff that matters.
Re:Wikihouse: Open-Source Houses by favorited on Tuesday January 09, 2024 @06:07PM (#38933630)
When I choose a concrete slab foundation, their price estimate tool gives me a range of £NaN - £NaN. Representing currency as a floating-point value strikes again.
Re:Wikihouse: Open-Source Houses by cpursley on Tuesday January 09, 2024 @06:42PM (#38934005)
There's a lesson here:

Lay your foundation with strong types.

Re:Wikihouse: Open-Source Houses by bawolff on Tuesday January 09, 2024 @07:08PM (#38934256)
What type are you supposed to use to represent total cost when spending infinite money for 0 days?
Re:Wikihouse: Open-Source Houses by shermantanktop on Tuesday January 09, 2024 @08:38PM (#38935041)
In Javascript? probably a different type than if you took 0 days to spend infinite money.
Re:Wikihouse: Open-Source Houses by cpursley on Tuesday January 09, 2024 @07:17PM (#38934333)
It seems the Romans took their concrete type secrets to the grave.
Re:Wikihouse: Open-Source Houses by 2toxic on Tuesday January 09, 2024 @09:14PM (#38935305)
Re:Wikihouse: Open-Source Houses by cyberax on Tuesday January 09, 2024 @10:17PM (#38935704)
Modern concrete with superplasticizers is far superior to Roman concrete.

The greatest limiting factor is not the concrete itself, but rebar. It will eventually rust, causing the concrete to spall and crack. So in most cases it makes no sense to really optimize the concrete lifetime, because why bother?

If you're willing to build structures that rely only on compression and gravity, then we can totally do stuff that the Romans never dreamt of. Just look at any modern concrete gravity dam as an example.

Re:Wikihouse: Open-Source Houses by quickthrower2 on Tuesday January 09, 2024 @10:47PM (#38935885)
You need refinement types. Psuedocode:

    timespandays : int, timespandays > 0
your program can then be proven by the compiler not to NaN.
Re:Wikihouse: Open-Source Houses by ericwood on Tuesday January 09, 2024 @07:06PM (#38934236)
The area defaults to zero, and recalculates when you change any of the parameters, resulting in a divide by zero and NaN being displayed
Re:Wikihouse: Open-Source Houses by actionfromafar on Tuesday January 09, 2024 @06:37PM (#38933958)
Typical Javascript strikes again?