Zulip Chat Archive

Stream: Is there code for X?

Topic: is_prime_field


Adam Topaz (Mar 26 2022 at 16:40):

What is the idiomatic way to say that a field K is a prime field (i.e. isomorphic to either Q\mathbb{Q} or Fp\mathbb{F}_p for some prime pp)?

Eric Rodriguez (Mar 26 2022 at 16:50):

here's a silly one: (n : \N) [field K] [is_fraction_ring (zmod n) K].

Eric Rodriguez (Mar 26 2022 at 16:51):

or maybe that includes F_p^ns, never mind

Adam Topaz (Mar 26 2022 at 16:53):

One option could be to say that any morphism of fields LKL \to K is an isomorphism (presumably where LL has the same universe level as KK)

Eric Rodriguez (Mar 26 2022 at 16:55):

that feels like a far more mathlibby definition, and leave the fact that they're isomorphic to F_p/Q as a theorem

Adam Topaz (Mar 26 2022 at 16:56):

Alternatively one could try to somehow say that KK is generated as a field by the image of the canonical ring hom from Z\mathbb{Z}.

Adam Topaz (Mar 26 2022 at 16:56):

But I don't know if we have a good way to say that.

Eric Rodriguez (Mar 26 2022 at 16:56):

why do we need them to be in the same universe?

Adam Topaz (Mar 26 2022 at 16:57):

If we want a characteristic predicate, we want to make sure that there aren't any additional universe parameters that are not necessary. So we could take LL to be in Type 0 or in Type u where K : Type u.

Adam Topaz (Mar 26 2022 at 16:57):

The two would be equivalent because there would be an isomorphism with Q\mathbb{Q} or Fp\mathbb{F}_p which are in Type 0.

Adam Topaz (Mar 26 2022 at 16:58):

But if we let L : Type v while K : Type u, then a priori there would be many predicates is_prime_field K which depend not only on u where K : Type u, but also on the v.

Adam Topaz (Mar 26 2022 at 18:27):

We can use docs#subfield.closure and say that the subfield generated by empty is top.

Adam Topaz (Mar 26 2022 at 18:29):

Or maybe just bot = top in subfield


Last updated: Dec 20 2023 at 11:08 UTC