-
Notifications
You must be signed in to change notification settings - Fork 465
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: BitVec.twoPow and lemmas, toward bitblasting multiplication for LeanSAT #4417
Conversation
Mathlib CI status (docs):
|
… LeanSAT We add a new definition `BitVec.twoPow w i` to represent `(1#w <<< i)`. This expression is used to test bits when building the multiplication bitblaster. Patch 1/?, being peeled from #6.
Co-authored-by: Tobias Grosser <[email protected]>
Mostly happy, but: Convince me that this needs a name, and shouldn't just be written out as its definition in all the statements. The proofs are less trivial than I expected (they are fine), and I think this justifies giving a name, but I just want to push back a little so we don't accumulate named entities needlessly! |
@semorrison That's somewhat of a hard ask :) I abstracted it precisely because dealing with the raw definitions was unwieldy. I've been mulling over this a little, and I wonder what the 'correct' approach is. The crux is that I want to break a bitvector into the bitwise-or of different
I wonder what you recommend in such a situation. I also wonder how |
No, I think your justification is satisfactory! Let's get the minor suggestions sorted out, and I can merge. |
I've fixed all nits now. |
awaiting-review |
We add a new definition
BitVec.twoPow w i
to represent(1#w <<< i)
.This expression is used to test bits when building the multiplication bitblaster.
Patch 1/?, being peeled from opencompl#6.