Skip to content

[Merged by Bors] - refactor: Unify spelling of "prime factors"#8164

Closed
YaelDillies wants to merge 6 commits intomasterfrom
prime_factors
Closed

[Merged by Bors] - refactor: Unify spelling of "prime factors"#8164
YaelDillies wants to merge 6 commits intomasterfrom
prime_factors

Conversation

@YaelDillies
Copy link
Copy Markdown
Contributor

@YaelDillies YaelDillies commented Nov 3, 2023

mathlib can't make up its mind on whether to spell "the prime factors of n" as n.factors.toFinset or n.factorization.support, even though those two are defeq. This PR proposes to unify everything to a new definition Nat.primeFactors, and streamline the existing scattered API about n.factors.toFinset and n.factorization.support to Nat.primeFactors. We also get to write a bit more API that didn't make sense before, eg primeFactors_mono.


Open in Gitpod

mathlib can't make up its mind on whether to spell "the prime factors of `n`" as `n.factors.toFinset` or `n.factorization.support`, even though those two are defeq. This PR proposes to unify everything to a new definition `Nat.primeFactors`, and stream the existing scattered API about `n.factors.toFinset` and `n.factorization.support` to `Nat.primeFactors`. We also get to write a bit more API that didn't make sense before, eg `primeFactors_mono`.
@YaelDillies YaelDillies added awaiting-review t-number-theory Number theory (also use t-algebra or t-analysis to specialize) labels Nov 10, 2023
Copy link
Copy Markdown
Member

@jcommelin jcommelin left a comment

Choose a reason for hiding this comment

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

Thanks 🎉

bors merge

@ghost ghost added ready-to-merge This PR has been sent to bors. and removed awaiting-review labels Nov 10, 2023
mathlib-bors bot pushed a commit that referenced this pull request Nov 10, 2023
mathlib can't make up its mind on whether to spell "the prime factors of `n`" as `n.factors.toFinset` or `n.factorization.support`, even though those two are defeq. This PR proposes to unify everything to a new definition `Nat.primeFactors`, and streamline the existing scattered API about `n.factors.toFinset` and `n.factorization.support` to `Nat.primeFactors`. We also get to write a bit more API that didn't make sense before, eg `primeFactors_mono`.
@mathlib-bors
Copy link
Copy Markdown
Contributor

mathlib-bors bot commented Nov 10, 2023

Pull request successfully merged into master.

Build succeeded:

@mathlib-bors mathlib-bors bot changed the title refactor: Unify spelling of "prime factors" [Merged by Bors] - refactor: Unify spelling of "prime factors" Nov 10, 2023
@mathlib-bors mathlib-bors bot closed this Nov 10, 2023
@mathlib-bors mathlib-bors bot deleted the prime_factors branch November 10, 2023 10:07
mathlib-bors bot pushed a commit that referenced this pull request Nov 12, 2023
@**Yaël Dillies**'s recent proof at #8164 uses `aesop` in a way that relies on `simp` using `decide := true` by default, which we have now disabled, and hence this breaks on `nightly-testing`.

I propose we add `@[aesop safe destruct]` to `Nat.not_prime_one` (and `Nat.not_prime_zero` while we're there).

Co-authored-by: Scott Morrison <scott.morrison@gmail.com>
alexkeizer pushed a commit that referenced this pull request Nov 17, 2023
@**Yaël Dillies**'s recent proof at #8164 uses `aesop` in a way that relies on `simp` using `decide := true` by default, which we have now disabled, and hence this breaks on `nightly-testing`.

I propose we add `@[aesop safe destruct]` to `Nat.not_prime_one` (and `Nat.not_prime_zero` while we're there).

Co-authored-by: Scott Morrison <scott.morrison@gmail.com>
alexkeizer pushed a commit that referenced this pull request Nov 21, 2023
@**Yaël Dillies**'s recent proof at #8164 uses `aesop` in a way that relies on `simp` using `decide := true` by default, which we have now disabled, and hence this breaks on `nightly-testing`.

I propose we add `@[aesop safe destruct]` to `Nat.not_prime_one` (and `Nat.not_prime_zero` while we're there).

Co-authored-by: Scott Morrison <scott.morrison@gmail.com>
grunweg pushed a commit that referenced this pull request Dec 15, 2023
mathlib can't make up its mind on whether to spell "the prime factors of `n`" as `n.factors.toFinset` or `n.factorization.support`, even though those two are defeq. This PR proposes to unify everything to a new definition `Nat.primeFactors`, and streamline the existing scattered API about `n.factors.toFinset` and `n.factorization.support` to `Nat.primeFactors`. We also get to write a bit more API that didn't make sense before, eg `primeFactors_mono`.
grunweg pushed a commit that referenced this pull request Dec 15, 2023
@**Yaël Dillies**'s recent proof at #8164 uses `aesop` in a way that relies on `simp` using `decide := true` by default, which we have now disabled, and hence this breaks on `nightly-testing`.

I propose we add `@[aesop safe destruct]` to `Nat.not_prime_one` (and `Nat.not_prime_zero` while we're there).

Co-authored-by: Scott Morrison <scott.morrison@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-to-merge This PR has been sent to bors. t-number-theory Number theory (also use t-algebra or t-analysis to specialize)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants