You're using numeric operations, but you're asking questions about bit vectors. Wouldn't you be better off storing your bit vectors as bits with
vec? Then you wouldn't have rounding errors caused by the numeric operations. Of course, if you're using them elsewhere as numbers, the conversion effort may not be worth it.