symengine / symengine.py

Python wrappers for SymEngine
MIT License
167 stars 64 forks source link

Feature Request: Add Support for Boolean Logic with Variables in SymEngine #497

Open PhysicsQoo opened 4 weeks ago

PhysicsQoo commented 4 weeks ago

I would like to request the addition of support for Boolean logic with variables in SymEngine. While SymEngine already supports Boolean constants (True and False), it currently lacks support for Boolean logic involving symbolic variables, which would represent unknown or variable truth values. Boolean variables are crucial for applications in fields like formal verification, logic synthesis, and constraint solving, where the values of variables can be either True or False. Adding support for Boolean variables and operations such as AND, OR, NOT, and more, would significantly enhance SymEngine's ability to handle problems in these domains.

rikardn commented 4 weeks ago

I agree. Symengine is open to contributions from anyone. If you'd like to get involved, submitting a pull request is a great way to get started. We're looking forward to seeing your ideas and working together to improve symengine.

isuruf commented 3 weeks ago

You can do something like,

And(Ne(x, 0), Ne(y, 0))