Note : This post is only for education purpose.
When you use the PLC program, you might see some equations in programming more or the less. Most of of the projects, in PLC work based on logical control such as ON and OFF. Sometimes we need to use some mathematics equation to control the process or system. Like Minterm and Maxterm, they are important parts of Boolean Algebra which can solve somehow in digital circuit and practical problems.
According to experts definition, Minterm means that is the product of N distinct literals where each literal occurs exactly once. The output of the minterm functions is 1. Minterm is represented by m. In the other hand, Maxterm is the sum of N distinct literals where each literals occurs exactly once. The output of the maxterm functions is 0. Maxterm is represented by M.
A sum of minterms is called the Sum Of Products (SOP) and a product of maxterms also called Product of Sum (POS).
Example of SOP is shown as below;
A’B + AC + BC
And then Example of POS is shown as below;
(A+B). (C+D)
For SOP there are crucial steps for Obtaining Minterms from Values.
1. We shall take the variable without complementing it if the Boolean variable's value is 1. For instance, if A is 1, we don't need to change A'.
2. 1. We shall take the variable complementing it if the Boolean variable's value is 0. For instance, if A is 0, we need to change A'.
Unlike SOP, POS has also have crucial steps for Obtaining Maxterms from Values but there is a little bit difference.
1. We shall take the variable without complementing it if the Boolean variable's value is 0. For instance, if A is 0, we don't need to change A'.
2. 1. We shall take the variable complementing it if the Boolean variable's value is 1. For instance, if A is 1, we need to change A'.
So how do we use this things to PLC program?
By using Karnaugh Map, also known as K-Map, can use in the program as Ladder diagram or Structure Text Language (STL). Using K-map, we can simply minimize Boolean equations with three or four variables without the need for any Boolean algebra theories. It is a tool for making Boolean expressions simpler in digital logic. The truth table values are used to organize the grid, which aids in the simplification of logic. I'm not going to show how to solve the equation but it want to show how it is very important in some degree in Logical Control.
As shown in figure, there are two tables. Using K-Map with these tables obtains equations which can easily use in the program. As you can imagine, without using K-Map, it might be difficult to think how to write the program and get the desire outputs.
Reference : geeksforgeeks, sanfoundry
Comments
Post a Comment