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

[Merged by Bors] - feat(ring_theory/valuation/basic): add add_valuation.valuation #12914

Closed
wants to merge 1 commit into from

Conversation

mariainesdff
Copy link
Collaborator


Open in Gitpod

@mariainesdff mariainesdff added the awaiting-review The author would like community review of the PR label Mar 24, 2022
@@ -492,6 +492,12 @@ variables {h0} {h1} {hadd} {hmul} {r : R}
@[simp]
theorem of_apply : (of f h0 h1 hadd hmul) r = f r := rfl

/-- The `valuation` associated to an `add_valuation` (useful if the latter is constructed using
`add_valuation.of`). -/
def valuation : valuation R (multiplicative (order_dual Γ₀)) := v
Copy link
Member

Choose a reason for hiding this comment

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

Does simps produce the lemma automatically?

Copy link
Collaborator Author

@mariainesdff mariainesdff Mar 29, 2022

Choose a reason for hiding this comment

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

@[simps] gives me the error message Invalid simps attribute. The body is not a constructor application: v

Copy link
Member

Choose a reason for hiding this comment

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

:( for simps, but thanks!

bors d+

@bors
Copy link

bors bot commented Mar 29, 2022

✌️ mariainesdff can now approve this pull request. To approve and merge a pull request, simply reply with bors r+. More detailed instructions are available here.

@mariainesdff
Copy link
Collaborator Author

bors r+

`add_valuation.of`). -/
def valuation : valuation R (multiplicative (order_dual Γ₀)) := v

@[simp] lemma valuation_apply (r : R) : v.valuation r = multiplicative.of_add (v r) := rfl
Copy link
Member

@eric-wieser eric-wieser Mar 29, 2022

Choose a reason for hiding this comment

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

This statement looks wrong to me - this should be

Suggested change
@[simp] lemma valuation_apply (r : R) : v.valuation r = multiplicative.of_add (v r) := rfl
@[simp] lemma valuation_apply (r : R) : v.valuation r = multiplicative.of_add (order_dual.to_dual (v r)) := rfl

(probably with line wrapping)

Let's fix this in a follow-up, so as not to interrupt the batch,

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Hmm I guess that makes sense, it's definitely what I meant. Why does rfl still work without the order_dual.to_dual?

@bors
Copy link

bors bot commented Mar 29, 2022

Pull request successfully merged into master.

Build succeeded:

@bors bors bot changed the title feat(ring_theory/valuation/basic): add add_valuation.valuation [Merged by Bors] - feat(ring_theory/valuation/basic): add add_valuation.valuation Mar 29, 2022
@bors bors bot closed this Mar 29, 2022
@bors bors bot deleted the add_valuation branch March 29, 2022 16:24
bors bot pushed a commit that referenced this pull request Mar 29, 2022
@YaelDillies YaelDillies removed the awaiting-review The author would like community review of the PR label Apr 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants