In: Computer Science
Develop a scenario with a series of logical statements that can be "solved" using k-maps. Once you have the scenario and logical statements, translate them into a truth table and use a k-map to build a simplified Boolean equation.
Solution for the algorithm is provided below. Please comment if you have any doubt.
Let us consider a three variable logical scenario, so that there should be three primitive logical statements,
Let,
A = The Day is too hot
B = The Night will be rain
C = Tomorrow will be cloudy
The scenario is:
The day is too hot and the night will be rain and tomorrow will be cloudy or the day is not too hot and the night will not rain and Tomorrow will be cloudy or the day is not too hot and the night will be rain and tomorrow will not be cloudy or The Day is not too hot and the night will not rain and tomorrow will be cloudy
Now the scenario in logical form is:
F = ABC +A’B’C+A’BC’+A’BC
That is in the min term form, F =M{1, 2, 5, 7}
Now the K-Map to solve the logical form is
Now the simplified form is = A’B+A’C+BC
That is the simplified logical scenario is:
The day is not too hot and the night will be rain or the day is not too hot and tomorrow will be cloudy or night will be rain and tomorrow will be cloudy