Home >>Python cmath Module >Python cmath.cos() Method

Python cmath.cos() Method

Python cmath.cos() Method

Python cmath.cos() method in python is used to returns the cosine of a complex number.

Syntax:
cmath.cos(x)

Parameter Values

Parameter Description
x It is required to find the cosine of a number
Here is an example of Python cmath.cos() Method:

import cmath
print (cmath.cos(5 + 3j))

Output:
(2.855815004227387+9.606383448432581j)
Example 2:

import cmath
print (cmath.cos(8 + 3j))

Output:
(-1.4648451607593584-9.911267173074599j)