OxiDD / oxidd

Concurrent decision diagram framework written in Rust
https://oxidd.net
Apache License 2.0
41 stars 5 forks source link

Set Operator Aliases #15

Open SSoelvsten opened 6 months ago

SSoelvsten commented 6 months ago

I might just be unable to find this function, but the binary diff operator (including operator overload for the - operator) is missing for oxidd::bdd_function and oxidd::bcdd_function. This operator is equivalent to f & ~g. With complement edges, one can safely do this using and and not; but without them, one needs a function to not compute/construct ~g.

SSoelvsten commented 6 months ago

Ah, it's called imp_strict.

nhusung commented 6 months ago

Note that compared to diff, imp_strict has operands swapped. I’d say this is a weak point of the current API, we should provide diff (and all other set operators) as aliases to the respective operators on Boolean functions. At some point, I also want to merge the BooleanVecSet trait (for sets of Boolean vectors; currently only part of the Rust API) into the BooleanFunction trait.

SSoelvsten commented 6 months ago

Yes, one can indeed interpret this issue as a missing alias.