The periodic function SIN returns the trigonometric sine of X.

## Examples

To find the sine of 0.5 radians and print the result, enter:

`PRINT, SIN(0.5)`

The following example plots the SIN function between 0 and 2π with 100 intervals:

`X = 2*!PI/100 * FINDGEN(100)PLOT, X, SIN(X)`

Note: !PI is a read-only system variable that contains the single-precision value for π.

Result = SIN(X)

## Return Value

Returns the double-precision floating-point, complex or single-precision floating-point value.

## Arguments

### X

The angle for which the sine is desired, specified in radians. If X is double-precision floating or complex, the result is of the same type. All other types are converted to single-precision floating-point and yield floating-point results. When applied to complex numbers:

SIN(x) = (EXP(i*x) - 1/EXP(i*x))/(2*i)

where i is defined as COMPLEX(0, 1).

If input argument X is an array, the result has the same structure, with each element containing the sine of the corresponding element of X.