What is precision of a number representation?

Chris Angelico rosuav at gmail.com
Mon Jul 11 21:57:16 EDT 2016


On Tue, Jul 12, 2016 at 8:17 AM, Ethan Furman <ethan at stoneleaf.us> wrote:
>> This is why it's important to be able to record precisions of
>> arbitrary numbers. If I then measure the width of this corridor with a
>> laser, I could get an extremely precise answer - say, 2,147
>> millimeters, with a precision of four significant digits, and
>> excellent accuracy. But if I multiply those numbers together to
>> establish the floor area of the corridor, the result does NOT have
>> four significant figures. It would be 64 square meters (not 64.41),
>> and the accuracy would be pretty low (effectively, the *in*accuracies
>> of both measurements get combined). But on the other hand, if you want
>> to know whether your new fridge will fit, you could measure it with
>> the same laser and come up with a figure of 1,973 mm (four sig fig),
>> which would mean your clearance is 174mm (four sig fig). How do you
>> record this? Is it 174.0? 0174? "174 with four significant figures"?
>
>
> 174.0, because those last tenths of a millimeter could be very important,
> while knowledge that there are no thousands of millimeters is already
> present.
>

But I never measured it to tenths of a millimeter. The display on my
laser measurer (I don't actually have one, by the way, so all this is
complete fabrication for the sake of the example) displays integer
millimeters, with an implicit "+/- 0.5 mm".

ChrisA



More information about the Python-list mailing list