9 natural logarithm (ln), 1 ) operation, 2 ) format – Yaskawa MP900 Series Ladder Programming Manual User Manual
Page 179: 3 ) programming example

5.6 Basic Function Instructions
5.6.9 Natural Logarithm (LN)
5-110
5.6.9 Natural Logarithm (LN)
( 1 ) Operation
The LN instruction calculates the natural logarithm of X (log
e
X), when input data X is a real number and stores the
result in the output data.
( 2 ) Format
∗ C and # registers cannot be used.
When Input Data Is Less Than or Equal to 0
If the input data is less than 0, the absolute value of the input data will be used to perform the operation and output the
result.
The output data is set to -
∞ if the input value is 0.
( 3 ) Programming Example
The following programming example calculates the natural logarithm when the input data is 2.718282 (
≈ e) in
MF00000, and stores the result in the output data in DF00000.
Log
e
2.718282
≈ log
e
e
→ DF00000 = 1.0
Input data
Output data
log
e
Input data
Output data
Icon:
Key entry: LN
Parameter Name
Applicable Data Types
B
W
L
F
A
Index
Constant
Input data (Src)
×
×
×
{
×
×
{
Output data (Dest)
×
×
×
{
*
×
×
×