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
include more rings in random testing #9777
Comments
comment:1
Here is a branch. But is this still pertinent ? New commits:
|
Author: Frédéric Chapoton |
Commit: |
Branch: public/ticket/9777 |
comment:2
any opinion on the pertinence ? |
comment:3
Is this doctest checking the right function? +
+def padic_field():
+ """
+ Return a random p-adic field modulo n with p at most 10000
+ and precision between 10 and 100.
+
+ EXAMPLES::
+
+ sage: import sage.rings.tests
+ sage: sage.rings.tests.integer_mod_ring()
+ Ring of integers modulo 30029
+ """
+ from sage.all import ZZ, Qp
+ prec = ZZ.random_element(x=10, y=100)
+ p = ZZ.random_element(x=2, y=10**4 - 30).next_prime()
+ return Qp(p, prec)
+
+ In any case, it would be nice to avoid adding new tests that require a specific random seed. We're pretty close to making all testing random testing. |
comment:4
I am not sure how useful this is for catching bugs as we do (or at least should do) good test coverage within the individual files/rings themselves. However, I would follow @orlitzky's recommendation as I don't have a strong opinion on this. |
comment:6
ok, should be better now |
Reviewer: Michael Orlitzky |
comment:7
Thanks! Many of these tests can probably be removed later on, but it's nice to have this old ticket fixed in the meantime, especially in the likely event that we all forget about it for another decade. |
comment:9
Merge conflict |
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:11
indeed a serious merge conflict. Needs another round of review, please |
comment:12
Still OK. |
Changed branch from public/ticket/9777 to |
p-adics should be included, perhaps at "level 0"?
The following "level 1" rings are not included in
sage.rings.tests
:power series rings
Laurent series rings
multivariate power series rings (implemented in implement multivariate truncated power series arithmetic #1956)
infinite polynomial rings
Also, it's not clear that "level n" testing occurs for
n > 1
; e.g. multivariate polynomial ring in 3 variables over Laurent series ring over finite field of size 29, etc.Quotient rings are also not included, but should be. There are probably more to be included than this list indicates.
CC: @tscrim @slel @kliem
Component: algebra
Keywords: random testing, rings
Author: Frédéric Chapoton
Branch/Commit:
8df28fa
Reviewer: Michael Orlitzky
Issue created by migration from https://trac.sagemath.org/ticket/9777
The text was updated successfully, but these errors were encountered: