Python | sympy.sin() method
In sympy, the sin() method is a sine function. Using the sin(x) method in the sympy module, we can compute the sine of x.
Syntax : sympy.sin(x)
Return : Returns the sine of x
Code #1: Below is the example using the sin() method to find the sine function.
Python3
from sympy import *
geek1 = sin( - 1 )
geek2 = sin(pi / 3 )
geek3 = sin(pi)
print (geek1)
print (geek2)
print (geek3)
|
Output:
-sin(1)
sqrt(3)/2
0
Code #2:
Python3
from sympy import *
geek = sin( 2 + 5j )
print (geek)
|
Output:
67.4789152384559 - 30.8794313435882*I
Last Updated :
01 Feb, 2023
Like Article
Save Article
Share your thoughts in the comments
Please Login to comment...