beautypg.com

Cos (cosine), Function, N is a number – Yaskawa LEGEND-MC User Manual

Page 95

background image

85

LEGEND-MC User’s Manual

@COS (Cosine)

[Function]

DESCRIPTION:

@COS returns the cosine of a number or variable given in square brackets using units of degrees. Note
that the @COS command is a function, which means that it does not follow the convention of the
commands, and does not require the underscore when used as an operand.

ARGUMENTS: @COS [n]

where

n is a number

USAGE:

EXAMPLES:

While Moving

Yes

Minimum n value

-32768

In a Program

Yes

Maximum n value

32768

Not in a program

Yes

Default Value

---

Can be Interrogated

No

Default Format

---

Used as an Operand

Yes

Distributed Control

No, Local

#TEST

Program TEST

VAR1=60

Set variable

MG @COS[VAR1]

Display the value of the sine of VAR1

VAR2=@COS[VAR1]+9

Perform calculation

EN

End of program