Numeric value of constants and precision
oshempek opened this issue · 2 comments
oshempek commented
What's the right way to return the numeric value of constants like pi and e up to a certain number of digits ? The hacky way I used was 'pi + 0.0' but that doesn't work with 'e + 0.0'. However 'e^(2.0)/e' returns the numeric value. But still, how would one go about setting a custom precision?
oshempek commented
Just figured out float() is probably the right way of getting the numeric value but is there an option to set the precision?
thunderkid commented
Haven't found a way. I notice there's a PR to hard-code it to 20 places instead of the usual 6, but nothing flexible.