Do you like bounded integrals?

tsbockman via Digitalmars-d digitalmars-d at puremagic.com
Mon Aug 29 11:20:05 PDT 2016


On Tuesday, 23 August 2016 at 20:40:06 UTC, Andrei Alexandrescu 
wrote:
> When composing, do the limits compose meaningfully?

They should. Generally speaking, if that doesn't produce 
reasonable bounds (leaving aside rounding errors) at the end of 
the computation, it means that the logic of the computation 
itself is wrong.

Ordinary abstract numbers don't really have "minimum" and 
"maximum" values; any variable that requires them has some sort 
of implied unit which determines its bounds. Therefore, the 
bounds should follow the rules of dimensional analysis 
(https://en.wikipedia.org/wiki/Dimensional_analysis).


More information about the Digitalmars-d mailing list