MyChat Scripts Engine: Sin
Computing the sine value in radians.
Syntax
function Sin(x: extended): extended;
Parameters and return values
Parameter |
Type |
Value |
x |
extended |
number from which you need to compute the sine. |
Function result
Sinus of a number in radians. Pi radian equals to 180 degrees.
Example
var
x: extended;
begin
x := sin(Pi / 6); // 30 degrees
mLogScript('Sin(Pi / 6) = ' + floattostr(x), '30 degrees');
end.
Script work result
[08:00:48] (Log "Sin"): [30 degrees] Sin(Pi / 6) = 0.500000000000