3 tangent (tan), 1) overview, 2) format – Yaskawa MP2000 Series: User's Manual for Motion Programming User Manual

Page 246: 3) programming examples

Advertising
background image

8.9 Basic Functions

8-139

8

Command Reference

8.9.3 Tangent (TAN)

(1) Overview

The TAN command uses the specified variable or constant (unit = degrees) as input and returns the tangent in a
real number register.

(2) Format

* Example: Calculates the tangent of the input value (

θ = 45.0°): TAN (θ) = 1.0

The TAN command can use only real number data. If bits, integers, or double integers are specified, an error
will result at compilation.

(3) Programming Examples

TAN command programming examples are shown below.

Motion Programs

Sequence Programs

Applicable

Applicable

MW00100 = TAN (1.0);

A B

Item Description

Unit

Usable Registers

A

Tangent

value

output

• All real number type registers (Excluding # and C registers)
• The above registers with subscript
• Subscript registers

B

Angle input

Degree

(

°)

• All real number type registers (Excluding # and C registers)
• The above registers with subscript
• Subscript registers
• Constants

DF00102=TAN(DF00100);

(1.0)

(45.0)

IMPORTANT

Type

Motion Programs/

Sequence Programs

Ladder Programs

B

W

L

F

DF00202=TAN(DF00200);

EXAMPLE

Advertising