### 8 releases

0.2.0 | Apr 22, 2023 |
---|---|

0.1.7 | Mar 27, 2023 |

0.1.5 | May 21, 2021 |

0.1.4 | Jul 13, 2020 |

0.1.0 | Nov 30, 2018 |

#**914** in Algorithms

**28** downloads per month

**MIT**license

675KB

9K
SLoC

# bex : binary expression toolkit

Bex is a rust crate for working with binary (Boolean) expressions.

This crate lets you build a complicated abstract syntax tree (AST) by working with individual Bit structs, or vectors that act like integers.

You can also "solve" these AST structures by converting them into various canonical representations:

**reduced, ordered, binary decision diagrams (ROBDDs)**-- a normal form consisting of if-then-else triples that essentially act like compressed truth tables**algebraic nomal form**-- an "xor of ands" polynomial form- (more coming in the future)

## Video introduction

J and Bex vs Primorial 15 is about converting "simple" factoring problems into boolean expressions and solving them with bex.

It covers the large factoring problems in examples/solve/bdd-solve.rs and the smaller tests in src/solve.rs

## Changes in 0.2.0

The main change here is that

is now 100 times faster, or more, depending on your CPU count.`BddBase`

The

structure has been heavily refactored, making use of the `BddSwarm`

module, and also
extracting `swarm`

for tracking dependencies between concurrent work-in-progress operations.`wip ::`WorkState

For full changelog, see CHANGELOG.md.

#### Dependencies

~2.6–8.5MB

~57K SLoC