boolean_algebra.karnaugh_map_simplification¶
https://en.wikipedia.org/wiki/Karnaugh_map https://www.allaboutcircuits.com/technical-articles/karnaugh-map-boolean-algebraic-simplification-technique
Functions¶
|
Main function to create and simplify a K-Map. |
|
Simplify the Karnaugh map. |
Module Contents¶
- boolean_algebra.karnaugh_map_simplification.main() None ¶
Main function to create and simplify a K-Map.
>>> main() [0, 1] [1, 1] Simplified Expression: A'B + AB' + AB
- boolean_algebra.karnaugh_map_simplification.simplify_kmap(kmap: list[list[int]]) str ¶
Simplify the Karnaugh map. >>> simplify_kmap(kmap=[[0, 1], [1, 1]]) “A’B + AB’ + AB” >>> simplify_kmap(kmap=[[0, 0], [0, 0]]) ‘’ >>> simplify_kmap(kmap=[[0, 1], [1, -1]]) “A’B + AB’ + AB” >>> simplify_kmap(kmap=[[0, 1], [1, 2]]) “A’B + AB’ + AB” >>> simplify_kmap(kmap=[[0, 1], [1, 1.1]]) “A’B + AB’ + AB” >>> simplify_kmap(kmap=[[0, 1], [1, ‘a’]]) “A’B + AB’ + AB”