Skip to content
Related Articles
Different uses of sine function in Julia – sinpi() and sinc() Method
• Last Updated : 21 Apr, 2020

The sinpi() is an inbuilt function in julia which is used to compute the value of which is more accurately than , where x is the large value.

Syntax: sinpi(x)

Parameters:

• x: Specified large value.

Returns: It returns the value of which is more accurately than .

Example:

 # Julia program to illustrate # the use of sinpi() method  # Getting the value of sin(pi x)println(sinpi(55))println(sinpi(22.7))println(sinpi(3.17))println(sinpi(22 / 7))

Output:

0.0
0.8090169943749488
-0.5090414157503711
-0.43388373911755795


#### sinc()

The sinc() is an inbuilt function in julia which is used to compute the value of .

Syntax: sinc(x)

Parameters:

• x: Specified value.

Returns: It returns the value of .

Example:

 # Julia program to illustrate # the use of sinc() method  # Getting the value of sin(pi x)/(pi x)println(sinc(0))println(sinc(1))println(sinc(3.14))println(sinc(22 / 7))

Output:

1
0
-0.043162343260348214
-0.04394392660493417


My Personal Notes arrow_drop_up