rocq-prover / rocq-prover/stdlib

Z.mod_mul_r and Z.rem_mul_r reversed

Open
#31 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Rocq Prover
Stars
42
Forks
38
Avg merge
14h 6m
Merged PRs (30d)
3

Description

Description of the problem
Check Z.mod_mul_r.
(* forall a b c : Z,
     b <> 0 -> c <> 0 -> Z.rem a (b * c) = Z.rem a b + b * Z.rem (a ÷ b) c *)
Check Z.rem_mul_r.
(* forall a b c : Z,
     b <> 0 -> 0 < c -> a mod (b * c) = a mod b + b * ((a / b) mod c) *)

Shouldn't these names be switched to be consistent with Nat.mod_mul_r and N.mod_mul_r, which both have similar conclusions to Z.rem_mul_r?

Coq Version

At least 8.8 - master.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Inspect the definitions of Z.mod_mul_r and Z.rem_mul_r, then compare their conclusions with Nat.mod_mul_r and N.mod_mul_r as described in the issue. Confirm whether the theorem names are reversed and update the relevant declarations so each name matches its conclusion.

Written by the indexing model from the issue text.

Assessment

Domain
devtools
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.