mathlib icon indicating copy to clipboard operation
mathlib copied to clipboard

feat(ring_theory/dedekind_domain/finite_adele_ring): add finite_adele_ring

Open mariainesdff opened this issue 3 years ago • 5 comments

We define the finite adèle ring of a Dedekind domain and show that it is a commutative ring.


Open in Gitpod

mariainesdff avatar May 19 '22 18:05 mariainesdff

@riccardobrasca is right and that we should be using the algebra typeclass more here. Even before we get to the adèles I think there are various little gaps to fill.

The job of algebra is to make it convenient to work with canonical ring morphisms and we have lots of these here. For example, I claim what is currently called inj_adic_completion_integers should really be instance : algebra R $ v.adic_completion_integers K.

Indeed, denoting the completion by $K_v$ and its integers by $R_v$, we have the commutative square:

R    ⟶ K
↓        ↓
R_v ⟶ K_v

and from this there are five algebra classes (the fifth one corresponding to the diagonal map). Of course algebra R K is part of the input but I think the other four are missing and I think should probably be added.

There will also be two is_scalar_tower instances and I guess also no_zero_smul_divisors instance(s) for the injectivity.

ocfnash avatar Jun 07 '22 16:06 ocfnash

Hmm, even the following seems to be missing:

import topology.algebra.uniform_ring
import algebra.algebra.basic

noncomputable theory

variables (A : Type*) [comm_ring A] [uniform_space A] [uniform_add_group A]
variables [topological_ring A] [uniform_add_group A]

local notation `A_hat` := uniform_space.completion A

instance ring_completion.algebra : algebra A A_hat :=
(uniform_space.completion.coe_ring_hom : A →+* A_hat).to_algebra

@[simp] lemma ring_completion.algebra_smul_eq (a : A) (x : A_hat) :
  a • x = (a : A_hat) * x :=
rfl

variables (R : Type*) [comm_ring R] [algebra R A]

instance ring_completion.algebra' : algebra R A_hat :=
((uniform_space.completion.coe_ring_hom : A →+* A_hat).comp (algebra_map R A)).to_algebra

@[simp] lemma ring_completion.algebra'_smul_eq (r : R) (x : A_hat) :
  r • x = (algebra_map R A r : A_hat) * x :=
rfl

instance ring_completion.is_scalar_tower : is_scalar_tower R A A_hat :=
⟨λ r k x,
begin
  simp only [←mul_assoc, algebra.smul_def, map_mul],
  congr,
end⟩

I'll look at this again first thing tomorrow and see if I can PR the missing general results.

ocfnash avatar Jun 07 '22 16:06 ocfnash

I'll look at this again first thing tomorrow and see if I can PR the missing general results.

Did you end up PRing this? I have been away at a conference, but now that I'm back I'll start working on your suggestions and Riccardo's.

mariainesdff avatar Jun 09 '22 12:06 mariainesdff

Did you end up PRing this?

Not yet (though I was hoping to get to it today). However if you can do it, then that would be even better.

ocfnash avatar Jun 09 '22 12:06 ocfnash

Not yet (though I was hoping to get to it today). However if you can do it, then that would be even better.

I can do it (but I don't know if I'll get to it today).

mariainesdff avatar Jun 10 '22 12:06 mariainesdff

Is it ready to be merged now?

mariainesdff avatar Jan 14 '23 11:01 mariainesdff

@eric-wieser, could you review the last changes? I think I replied to all of your comments.

mariainesdff avatar Feb 22 '23 12:02 mariainesdff

Just in case you missed it, I also responded to an earlier comment at https://github.com/leanprover-community/mathlib/pull/14249#discussion_r1114263296

eric-wieser avatar Feb 22 '23 13:02 eric-wieser

:v: 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.

bors[bot] avatar Feb 23 '23 18:02 bors[bot]

bors merge

ocfnash avatar Feb 24 '23 13:02 ocfnash

Pull request successfully merged into master.

Build succeeded:

bors[bot] avatar Feb 24 '23 15:02 bors[bot]