Learn PLCs free
2 min read
Updated 2025-11-10
Beginner

MUL

MUL

MUL means Multiplication — a function block that computes the product of two or more values. Used in PLC programming for scaling analog inputs, calibration calculations, and gear-ratio math.

Key Takeaways

  • MUL means Multiplication — a function block that computes the product of two or more values. Used in PLC programming for...
  • Beginner-level topic in Functions & Function Blocks
  • Commonly used in: Manufacturing process control and automation, Quality control and inspection systems
  • Related to: ADD, SUB, DIV

Detailed Definition

MUL is the multiplication instruction in PLC programming, used to compute the product of two or more numeric values. It is one of the standard arithmetic functions defined in IEC 61131-3 alongside ADD, SUB, and DIV.

**MUL in Different PLC Programming Languages:**

**Ladder Logic (Function Block style):** In ladder logic, MUL appears as a function block with two inputs and one output. Wire the multiplicand and multiplier to the inputs; the product appears at the output. Most PLCs also support the MUL instruction as an AOI or built-in block.

**Structured Text:** ``` result := value1 * value2; // Simple multiplication scaledValue := rawAnalog * 0.00488; // Scale 12-bit ADC to volts totalCost := unitPrice * quantity; // Production calculation ``` In Structured Text, the `*` operator performs the same function as the MUL block.

**Instruction List (IL):** ``` LD value1 MUL value2 ST result ```

**Function Block Diagram (FBD):** Drag the MUL block from the math library, connect inputs EN, IN1, IN2 and output OUT.

**Common Applications of MUL in PLC Programs:** - Scaling analog inputs: `engineeringValue := (rawADC * span) / 4095 + offset` - Flow rate calculations: `totalFlow := flowRate * elapsedTime` - Unit conversions: `meters := inches * 0.0254` - Cost/production calculations: `batchWeight := bagCount * bagWeight` - PID output scaling: `valvePosition := pidOutput * maxTravel / 100`

**Data Type Considerations:** When multiplying two INT values, the result can exceed the INT range (-32,768 to 32,767). For example, 200 * 200 = 40,000 which overflows INT. Always store multiplication results in a data type large enough to hold the maximum possible product — typically DINT (32-bit) or REAL (floating point).

**Platform-Specific Notes:** - **Allen-Bradley (Logix5000):** Use the MUL instruction. Source A × Source B = Destination. Supports INT, DINT, and REAL. - **Siemens (TIA Portal):** Use MUL_E block in LAD/FBD or the `*` operator in SCL. Watch for implicit type conversions. - **CODESYS:** Standard `*` operator or MUL function block. Supports all IEC numeric types.

Why It Matters

Understanding MUL is fundamental in PLC programming and industrial automation. This concept plays a vital role in:

  • Manufacturing process control and automation
  • Quality control and inspection systems
  • Safety system implementation and monitoring
  • Data acquisition and process monitoring
  • System integration and communication

Mastering this essential concept will enhance your ability to design, implement, and troubleshoot industrial automation systems effectively.

Real-World Use Cases

MUL is applied across various industrial automation scenarios:

Manufacturing process control and automation

Quality control and inspection systems

Safety system implementation and monitoring

Data acquisition and process monitoring

System integration and communication

Practical Examples

Here are real-world examples of how MUL is implemented in industrial settings:

1

Implementation of MUL in a pharmaceutical manufacturing line for FDA-compliant batch tracking and control

2

Using MUL in automotive assembly plant for coordinating robotic welding stations with sub-millimeter precision

3

Application of MUL in water treatment facility providing redundant control for critical process parameters

Pro Tip: These examples demonstrate common implementation patterns. Adapt them to your specific application requirements and PLC platform.

Common Questions

What is MUL?

MUL means Multiplication — a function block that computes the product of two or more values. Used in PLC programming for scaling analog inputs, calibration calculations, and gear-ratio math.

Is MUL suitable for beginners?

Yes! MUL is classified as a beginner-level concept, making it an excellent starting point for those new to PLC programming and industrial automation.

When should I use MUL?

MUL is particularly useful in scenarios such as Manufacturing process control and automation and Quality control and inspection systems. Consider implementing it when you need reliable, efficient solutions for these types of applications.

What are related concepts I should learn?

To fully understand MUL, you should also familiarize yourself with ADD, SUB, and DIV. These concepts work together in industrial automation systems.

Was this helpful?

Let us know if this glossary term helped you understand MUL better.

Your feedback helps us improve our glossary and create better content for the PLC programming community.

About Functions & Function Blocks

Reusable code blocks, standard functions, and custom libraries

Total Terms:20
Difficulty:Intermediate to Advanced

Free PLC simulator

Stop reading, start doing

Write ladder logic in your browser, hit Run, and watch real machine scenarios react. 12 guided lessons across 8 PLC dialects — free account, no credit card.

Practice PLCs free →