Java, .NET, PHP, PYTHON, ANGULAR, ML, Data Science, Testing, CI Tutorials in Easy Languages.

"Best Software Training, Internship, Project Development center of Indore India, Helpline 780506-3968"

Constant package of SCIPY:-


It is used to provide a value of the constant in data science mathematical operation, Scipy provide the constant package to get the value of all standard constant.


from scipy.constants import pi

import scipy
from scipy.constants import pi
print("sciPy - pi = %.16f" % scipy.constants.pi)
#print(scipy.constants.find())
print(scipy.constants.physical_constants["alpha particle mass"])



Another example:-

import scipy
from scipy.constants import pi
print(pi)
print(scipy.constants.golden)
print(scipy.constants.c)
print(scipy.constants.Avogadro)
print(scipy.constants.find())
print(scipy.constants.physical_constants["alpha particle mass"])





Post a Comment

If you have any doubt in programming or join online classes then you can contact us by comment .

Previous Post Next Post