Skip to main content

6.1.3.4.4 MUL

Function

Multiply ( * ), multiply the value of input IN1 by the value of input IN2, and output OUT (OUT:=IN1 * IN2)

LD Graphics

alt text

Parameter description

Interface variableDeclarationData typeDescription
IN1Var_InputANY_NUMMultiplier 1
IN2Var_InputANY_NUMMultiplier 2
OUTVar_OutputANY_NUMOUT:=IN1*IN2

Example

The result obtained by multiplying the value of variable a by the value of variable b is given to variable c through the MUL instruction, as shown in the figure below: three INT type variables are defined, and the SUB instruction is executed by compiling, downloading, and realizing c:=a*b

alt text

warning
  • MUL is an extensible function, and inputs can be added by clicking the "+" in the LD graph