boolean.py icon indicating copy to clipboard operation
boolean.py copied to clipboard

Same operands in AND expression after simplification

Open tomas789 opened this issue 2 years ago • 1 comments

When simplifying the expression

AND(TRUE, OR(OR(symbol("x0"), FALSE), AND(symbol("x2"), TRUE), NOT(TRUE)), AND(AND(TRUE, TRUE, symbol("x2"), TRUE), NOT(symbol("x0"))))

Which produces the expression

AND(NOT(Symbol('x0')), Symbol('x2'), Symbol('x2'))

Which could be trivially simplified to

AND(NOT(Symbol('x0')), Symbol('x2'))

tomas789 avatar Nov 16 '22 14:11 tomas789

I can confirm that the PR https://github.com/bastikr/boolean.py/pull/113 also fixes this issue.

tomas789 avatar Nov 29 '22 09:11 tomas789