This is a package we found useful while developing Yao.jl, it stays inside Yao.jl for more than half a year, it takes an important role in making Yao a high performance quantum simulator, and we decided to move it to an extern package recently to let more people use it easily.

We provide several useful tools **when you need deal with eigen vectors in linear space marked with bits**, e.g on a quantum computer with qubits model, we use |00\cdots 00\rangle, \dots |11\cdots 11\rangle to represent the eigen vectors in its hilbert space.

Moreover, other people work on spins, bits etc. may find this useful as well. e.g to represent a set of spins one can use this representation and have to do some similar manipulations on it as well.

We provide **high performance**, **elegant** bit manipulation tools in `BitBasis`

, which includes:

- linear space basis iterator: itercontrol, reorder
- high performance mask based methods
- bit manipulation functions (start with
`b`

) like`breflect`

,`btruncate`

,`swapbits`

etc. - bit string literals, supports most of the methods above, while supporting some sugars as well, e.g it will automatically do the indexing conversion when you use it for matrix/vector indexing

This package is currently in beta, for feature request and bug reports please feel free to open issue for us!