sage.rings.function_field: Update # needs#35957
Conversation
…ntl' when GF2X is used
…only-tags src/sage/rings/function_field
There was a problem hiding this comment.
I have not checked every files yet. I have the same kind of remarks in all files: some # needs sage.rings.function_field should at least be at the level of blocks, many # needs sage.rings.finite_rings statements could be at top level and may be sage.rings.function_field too.
| sage: latex(w) # optional - sage.rings.finite_rings | ||
| sage: # needs sage.rings.finite_rings | ||
| sage: K.<x> = FunctionField(GF(4)); _.<Y> = K[] | ||
| sage: L.<y> = K.extension(Y^3 + x + x^3*Y) |
There was a problem hiding this comment.
I don't understand why # needs sage.rings.function_field is not needed here
There was a problem hiding this comment.
Right... It is needed here too. But I currently don't have a working modularized distribution with which I could test either non-prime finite fields or function field extensions. So when doctests are already marked # needs sage.rings.finite_rings, the system cannot detect that other # needs tags are needed.
I'll check if I can get sagemath-pari in working order to improve this situation.
There was a problem hiding this comment.
OK. Now my script was able to add this tag automatically.
| sage: {x.differential(): 1} # optional - sage.rings.finite_rings sage.rings.function_field | ||
| sage: # needs sage.rings.finite_rings | ||
| sage: K.<x> = FunctionField(GF(2)); _.<Y> = K[] | ||
| sage: L.<y> = K.extension(Y^3 + x + x^3*Y) # needs sage.rings.function_field |
| sage: 1/(2*z) * y.differential() # optional - sage.rings.finite_rings sage.rings.function_field | ||
| sage: 1/(2*z) * y.differential() # needs sage.rings.function_field | ||
| (8/x*z) d(x) | ||
|
|
There was a problem hiding this comment.
removing this empty line should allow to avoid needs sage.rings.finite_rings in the next examples, no ?
There was a problem hiding this comment.
Yes, but I have instead added a block # needs tag
| sage: I = O.ideal(y) # optional - sage.rings.function_field | ||
| sage: I.divisor() # optional - sage.rings.function_field | ||
| sage: L.<y> = K.extension(Y^2 + Y + x + 1/x) # needs sage.rings.function_field | ||
| sage: O = L.maximal_order() # needs sage.rings.function_field |
There was a problem hiding this comment.
actually, since we have # needs sage.rings.function_field, it could be at the top level of the file, no ?
There was a problem hiding this comment.
The feature sage.rings.function_field indicates that the full function field functionality (in particular, extensions) is available.
function_field.py however is shipped with the distribution sagemath-categories to make rational function fields available, and that's what a portion of the tests here are testing.
| sage: f = Y^2 - x*Y + x^2 + 1 # irreducible but not absolutely irreducible # optional - sage.rings.finite_rings | ||
| sage: L.<y> = K.extension(f) # optional - sage.rings.finite_rings | ||
| sage: L.genus() # optional - sage.rings.finite_rings | ||
| sage: # needs sage.rings.finite_rings |
There was a problem hiding this comment.
sage.rings.finite_rings is for almost all lines of examples / test that It could be at the top of the file.
There was a problem hiding this comment.
Actually because prime finite fields are always available now, I was able to remove most of these tags.
…stribution sagemath-pari, sagemath-modules, sagemath-modules[pari]
…s.finite_rings when only prime finite fields are used; use more block tags
…rings when only prime finite fields are used; use more block tags
…n only prime finite fields are used; use more block tags
…n only prime finite fields are used; use more block tags
…gs --probe all src/sage/rings/function_field/
|
Documentation preview for this PR (built with commit 61654eb; changes) is ready! 🎉 |
|
It seems better now. Do you have further improvements to do here ? |
|
It's ready from my side |
dcoudert
left a comment
There was a problem hiding this comment.
This is much lighter this way.
LGTM.
|
Thank you! |
# optionalare removed because small prime finite fields no longer need to be marked# optional/needs sage.rings.finite_ringssince Integer.{perfect_power,is_prime_power,is_irreducible}: Handle easy cases without PARI #35847# optionalare replaced by codeblock-scoped# needstags# optionalwith standard features are replaced by# needsThis is:
sage -fixdoctestsfrom Add style guide / reference for# optional - sage....doctest tags, extendsage -tandsage -fixdoctestsfor modularization tasks #35749📝 Checklist
⌛ Dependencies