"Strong typing vs. strong testing"
arnodel at gmail.com
Wed Oct 13 15:23:28 CEST 2010
Tim Bradshaw <tfb at tfeb.org> writes:
> On 2010-10-13 13:21:29 +0100, BartC said:
>> My money would have been on 0.25, based on using 1.0 for a 360°
>> circular angle. It seems far more attractive than using the
>> arbitrary-looking 6.28...
> It may look arbitrary, but it isn't: it's about as non-arbitrary as it
> is possible to be.
Consider a few formulae that kids learn at school.
In radians, given an angle θ in a circle of radius r:
* length of arc = rθ
* area of sector = 1/2 r²θ
* d/dx(sin x) = cos x
* d/dx(cos x) = -sinx x
Let's use 1 for the angle 2π. Then:
* length of arc = 2πrθ
* area of sector = πr²θ
* d/dx(sin x) = 2πcos x
* d/dx(cos x) = 2πsin x
We've removed one π, but now π crops up in every formula!
More information about the Python-list