Explore Courses Blog Tutorials Interview Questions
0 votes
in Python by (12.7k points)

Can anyone tell me how to install sympy package in python?

1 Answer

0 votes
by (26.4k points)

Check the below steps:

You can also use pip3 install sympy on MacOS.

  1. List item
  2. Open your "Terminal".
  3. Input pip3 install sympy and press enter.
  4. It will automatically download and install the Sympy Package.

Once after finishing the installation, try to open the python IDLE and try:

from sympy import Symbol, cos

x = Symbol('x')

e = 1/cos(x)

print(e.series(x, 0, 10))

# Result

# 1 + x**2/2 + 5*x**4/24 + 61*x**6/720 + 277*x**8/8064 + O(x**10)

If it works, It will show that "Sympy" Package has been installed.

Are you pretty much interested to learn python in detail? Come and join the python training course to gain more knowledge.

Related questions

0 votes
1 answer
0 votes
1 answer
0 votes
1 answer
0 votes
1 answer
asked Apr 18, 2021 in Python by laddulakshana (12.7k points)

Browse Categories