I have a question regarding the inaccuracy in calculated area by Python and actual value. I searched a lot about it but I didn't find anything. I'm afraid that this difference made my next calculations inaccurate. Here is the code that I calculated with it the area of a circle with radius 1.5:
from shapely.geometry import Point, Polygon
a = Point(1, 1).buffer(1.5)
print (a.area)
and the result that I got is:
7.05723410373
But the actual value for area of the circle with radius 1.5 is:
pi()*(1.5^2) = 7.0685834705
Can anybody explain this difference for me? Should I change any default value on my computer?
Also here is the pi()
value of my computer:
import math
print (math.pi)
which is exactly as same as actual pi()
value:
3.14159265359