Skip to content
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: getLsb_replicate #4873

Merged
merged 5 commits into from
Aug 1, 2024
Merged

Conversation

bollu
Copy link
Contributor

@bollu bollu commented Jul 30, 2024

This allows bitblasting BitVec.replicate.

I changed the definition of BitVec.replicate to use BitVec.cast in order to make the proof smoother, since it's an easier time simplifying away terms with BitVec.cast.

This allows bitblasting `BitVec.replicate`.
@github-actions github-actions bot added the toolchain-available A toolchain is available for this PR, at leanprover/lean4-pr-releases:pr-release-NNNN label Jul 30, 2024
@leanprover-community-mathlib4-bot
Copy link
Collaborator

leanprover-community-mathlib4-bot commented Jul 30, 2024

Mathlib CI status (docs):

  • ❗ Batteries/Mathlib CI will not be attempted unless your PR branches off the nightly-with-mathlib branch. Try git rebase afe0b5a01326a99fb18049d29d7f62a5ffc83c15 --onto 69f86d6478a944865969abebc45f9417b212a5fc. (2024-07-30 21:36:06)
  • ❗ Batteries/Mathlib CI will not be attempted unless your PR branches off the nightly-with-mathlib branch. Try git rebase afe0b5a01326a99fb18049d29d7f62a5ffc83c15 --onto 8acdafd5b3957382c02779ada451c14da44e2aca. (2024-07-31 14:27:46)
  • ❗ Batteries/Mathlib CI will not be attempted unless your PR branches off the nightly-with-mathlib branch. Try git rebase e83f78d5af8887d2d384e2405adf85e3ee72fec4 --onto 8acdafd5b3957382c02779ada451c14da44e2aca. (2024-08-01 07:25:30)

@tobiasgrosser
Copy link
Contributor

tobiasgrosser commented Jul 31, 2024

Hey, this looks good to me. Let's see what @alexkeizer says, but you may be able to undraft this PR after @alexkeizer gives feedback.

@kim-em kim-em added the awaiting-author Waiting for PR author to address issues label Jul 31, 2024
@bollu
Copy link
Contributor Author

bollu commented Jul 31, 2024

awaiting-review

@github-actions github-actions bot added awaiting-review Waiting for someone to review the PR and removed awaiting-author Waiting for PR author to address issues labels Jul 31, 2024
@bollu bollu marked this pull request as ready for review July 31, 2024 18:40
@@ -203,6 +203,10 @@ theorem mod_add_div (m k : Nat) : m % k + k * (m / k) = m := by
| base x y h => simp [h]
| ind x y h IH => simp [h]; rw [Nat.mul_succ, ← Nat.add_assoc, IH, Nat.sub_add_cancel h.2]

theorem mod_def (m k : Nat) : m % k = m - k * (m / k) := by
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Technically this is not the definition for Nat, but I like the parallelism with the Int naming, and will worry about whether this needs to be changed later.

@kim-em kim-em removed the awaiting-review Waiting for someone to review the PR label Aug 1, 2024
@kim-em kim-em added this pull request to the merge queue Aug 1, 2024
Merged via the queue into leanprover:master with commit ee430b6 Aug 1, 2024
13 checks passed
@leanprover-bot leanprover-bot added the P-high We will work on this issue label Aug 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P-high We will work on this issue toolchain-available A toolchain is available for this PR, at leanprover/lean4-pr-releases:pr-release-NNNN
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants