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

set reverse=True by default in basis_for_quaternion_lattice() #34962

Conversation

yyyyx4
Copy link
Member

@yyyyx4 yyyyx4 commented Feb 6, 2023

Fixes #34880.

@yyyyx4 yyyyx4 marked this pull request as ready for review February 6, 2023 10:03
@codecov-commenter
Copy link

Codecov Report

Base: 88.61% // Head: 88.59% // Decreases project coverage by -0.02% ⚠️

Coverage data is based on head (9b9f05c) compared to base (9116c55).
Patch coverage: 100.00% of modified lines in pull request are covered.

📣 This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more

Additional details and impacted files
@@             Coverage Diff             @@
##           develop   #34962      +/-   ##
===========================================
- Coverage    88.61%   88.59%   -0.02%     
===========================================
  Files         2136     2136              
  Lines       396138   396141       +3     
===========================================
- Hits        351020   350974      -46     
- Misses       45118    45167      +49     
Impacted Files Coverage Δ
src/sage/modular/quatalg/brandt.py 94.00% <ø> (ø)
src/sage/algebras/quatalg/quaternion_algebra.py 92.68% <100.00%> (ø)
src/sage/cpython/_py2_random.py 74.79% <0.00%> (-1.66%) ⬇️
...e/combinat/cluster_algebra_quiver/mutation_type.py 52.49% <0.00%> (-1.43%) ⬇️
src/sage/modular/hecke/algebra.py 94.65% <0.00%> (-1.07%) ⬇️
src/sage/modular/modform/numerical.py 94.19% <0.00%> (-0.65%) ⬇️
src/sage/graphs/generators/random.py 91.95% <0.00%> (-0.52%) ⬇️
src/sage/sets/integer_range.py 91.41% <0.00%> (-0.51%) ⬇️
src/sage/graphs/generic_graph.py 89.14% <0.00%> (-0.46%) ⬇️
...ge/schemes/elliptic_curves/weierstrass_morphism.py 93.01% <0.00%> (-0.44%) ⬇️
... and 16 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@codecov-commenter
Copy link

codecov-commenter commented Feb 8, 2023

Codecov Report

Base: 88.57% // Head: 88.59% // Increases project coverage by +0.01% 🎉

Coverage data is based on head (97916e0) compared to base (52a81cb).
Patch coverage: 100.00% of modified lines in pull request are covered.

❗ Current head 97916e0 differs from pull request most recent head c9c0bc7. Consider uploading reports for the commit c9c0bc7 to get more accurate results

Additional details and impacted files
@@             Coverage Diff             @@
##           develop   #34962      +/-   ##
===========================================
+ Coverage    88.57%   88.59%   +0.01%     
===========================================
  Files         2140     2140              
  Lines       397273   396961     -312     
===========================================
- Hits        351891   351677     -214     
+ Misses       45382    45284      -98     
Impacted Files Coverage Δ
src/sage/modular/quatalg/brandt.py 94.00% <ø> (ø)
src/sage/algebras/quatalg/quaternion_algebra.py 92.68% <100.00%> (ø)
...e/combinat/cluster_algebra_quiver/mutation_type.py 49.40% <0.00%> (-2.74%) ⬇️
...c/sage/schemes/elliptic_curves/ell_finite_field.py 87.57% <0.00%> (-1.27%) ⬇️
src/sage/combinat/matrices/hadamard_matrix.py 84.43% <0.00%> (-1.01%) ⬇️
src/sage/modular/modform/numerical.py 94.19% <0.00%> (-0.65%) ⬇️
...sage/geometry/hyperbolic_space/hyperbolic_model.py 88.95% <0.00%> (-0.62%) ⬇️
src/sage/doctest/forker.py 80.24% <0.00%> (-0.54%) ⬇️
src/sage/combinat/t_sequences.py 94.68% <0.00%> (-0.49%) ⬇️
src/sage/doctest/reporting.py 74.45% <0.00%> (-0.44%) ⬇️
... and 48 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@yyyyx4 yyyyx4 force-pushed the public/reverse_by_default_in_basis_for_quaternion_lattice branch from 5829c68 to 97916e0 Compare February 14, 2023 00:20
@yyyyx4 yyyyx4 force-pushed the public/reverse_by_default_in_basis_for_quaternion_lattice branch from 97916e0 to c9c0bc7 Compare February 25, 2023 02:57
@kwankyu
Copy link
Collaborator

kwankyu commented Mar 31, 2023

@tornaria

@yyyyx4 yyyyx4 force-pushed the public/reverse_by_default_in_basis_for_quaternion_lattice branch 2 times, most recently from df84a0b to eed894f Compare April 7, 2023 01:19
@yyyyx4 yyyyx4 force-pushed the public/reverse_by_default_in_basis_for_quaternion_lattice branch from eed894f to 60f1abc Compare April 14, 2023 03:11
@yyyyx4 yyyyx4 force-pushed the public/reverse_by_default_in_basis_for_quaternion_lattice branch from 60f1abc to 5b3664e Compare May 24, 2023 05:08
@kwankyu
Copy link
Collaborator

kwankyu commented May 26, 2023

I agree that this is a good change.

But this is an API change of the function basis_for_quaternion_lattice. So a deprecation warning seems required.

@yyyyx4 yyyyx4 marked this pull request as draft May 26, 2023 11:06
@github-actions
Copy link

github-actions bot commented Aug 21, 2023

Documentation preview for this PR (built with commit 14c2efd; changes) is ready! 🎉
This preview will update shortly after each push to this PR.

@yyyyx4 yyyyx4 marked this pull request as ready for review August 22, 2023 10:12
@kwankyu
Copy link
Collaborator

kwankyu commented Aug 23, 2023

Deprecation period is one year.

@yyyyx4 yyyyx4 force-pushed the public/reverse_by_default_in_basis_for_quaternion_lattice branch from 06e078a to 09aea38 Compare August 8, 2024 15:12
@yyyyx4 yyyyx4 force-pushed the public/reverse_by_default_in_basis_for_quaternion_lattice branch from 09aea38 to 2fa6517 Compare August 10, 2024 21:57
@kwankyu
Copy link
Collaborator

kwankyu commented Aug 11, 2024

sage -t --warn-long 65.7 --random-seed=172242929068586131357270719533848860749 src/sage/schemes/elliptic_curves/heegner.py
**********************************************************************
File "src/sage/schemes/elliptic_curves/heegner.py", line 4906, in sage.schemes.elliptic_curves.heegner.HeegnerQuatAlg.right_ideals
Failed example:
    heegner_points(11).reduce_mod(3).right_ideals()
Expected:
    (Fractional ideal (2 + 2*j + 28*k, 2*i + 26*k, 4*j + 12*k, 44*k),
     Fractional ideal (2 + 2*j + 28*k, 2*i + 4*j + 38*k, 8*j + 24*k, 88*k))
Got:
    (Fractional ideal (4, 44*i, 2 + 8*i + 2*j, 34*i + 2*k),
     Fractional ideal (8, 88*i, 2 + 52*i + 2*j, 4 + 78*i + 2*k))
**********************************************************************
File "src/sage/schemes/elliptic_curves/heegner.py", line 5137, in sage.schemes.elliptic_curves.heegner.HeegnerQuatAlg.cyclic_subideal_p1
Failed example:
    sorted(H.cyclic_subideal_p1(I, 3).items())
Expected:
    [((0, 1),
      Fractional ideal (2 + 2*j + 32*k, 2*i + 8*j + 82*k, 12*j + 60*k, 132*k)),
     ((1, 0),
      Fractional ideal (2 + 10*j + 28*k, 2*i + 4*j + 62*k, 12*j + 60*k, 132*k)),
     ((1, 1),
      Fractional ideal (2 + 2*j + 76*k, 2*i + 4*j + 106*k, 12*j + 60*k, 132*k)),
     ((1, 2),
      Fractional ideal (2 + 10*j + 116*k, 2*i + 8*j + 38*k, 12*j + 60*k, 132*k))]
Got:
    [((0, 1), Fractional ideal (12, 132*i, 10 + 76*i + 2*j, 4 + 86*i + 2*k)),
     ((1, 0), Fractional ideal (12, 132*i, 2 + 32*i + 2*j, 8 + 130*i + 2*k)),
     ((1, 1), Fractional ideal (12, 132*i, 10 + 32*i + 2*j, 8 + 86*i + 2*k)),
     ((1, 2), Fractional ideal (12, 132*i, 2 + 76*i + 2*j, 4 + 130*i + 2*k))]
**********************************************************************
File "src/sage/schemes/elliptic_curves/heegner.py", line 5269, in sage.schemes.elliptic_curves.heegner.HeegnerQuatAlg.kolyvagin_cyclic_subideals
Failed example:
    H.kolyvagin_cyclic_subideals(I, 5, alpha_quaternion)
Expected:
    [(Fractional ideal (2 + 2/3*i + 364*j + 231928/3*k,
                        4/3*i + 946*j + 69338/3*k,
                        1280*j + 49920*k, 94720*k), 0),
     (Fractional ideal (2 + 2/3*i + 108*j + 31480/3*k,
                        4/3*i + 434*j + 123098/3*k,
                        1280*j + 49920*k, 94720*k), 1),
     (Fractional ideal (2 + 2/3*i + 876*j + 7672/3*k,
                        4/3*i + 434*j + 236762/3*k,
                        1280*j + 49920*k, 94720*k), 2),
     (Fractional ideal (2 + 2/3*i + 364*j + 61432/3*k,
                        4/3*i + 178*j + 206810/3*k,
                        1280*j + 49920*k, 94720*k), 3),
     (Fractional ideal (2 + 2/3*i + 876*j + 178168/3*k,
                        4/3*i + 1202*j + 99290/3*k,
                        1280*j + 49920*k, 94720*k), 4),
     (Fractional ideal (2 + 2/3*i + 1132*j + 208120/3*k,
                        4/3*i + 946*j + 183002/3*k,
                        1280*j + 49920*k, 94720*k), 5)]
Got:
    [(Fractional ideal (2560, 1280 + 47360*i, 1146 + 37678*i + 4*j, 212 + 54664/3*i + 2*j + 2/3*k),
      0),
     (Fractional ideal (2560, 1280 + 47360*i, 2426 + 9262*i + 4*j, 2004 + 83080/3*i + 2*j + 2/3*k),
      1),
     (Fractional ideal (2560, 1280 + 47360*i, 1914 + 9262*i + 4*j, 1748 + 111496/3*i + 2*j + 2/3*k),
      2),
     (Fractional ideal (2560, 1280 + 47360*i, 2170 + 18734*i + 4*j, 212 + 111496/3*i + 2*j + 2/3*k),
      3),
     (Fractional ideal (2560, 1280 + 47360*i, 890 + 28206*i + 4*j, 1748 + 54664/3*i + 2*j + 2/3*k),
      4),
     (Fractional ideal (2560, 1280 + 47360*i, 634 + 37678*i + 4*j, 2516 + 83080/3*i + 2*j + 2/3*k),
      5)]
**********************************************************************
3 items had failures:
   1 of   5 in sage.schemes.elliptic_curves.heegner.HeegnerQuatAlg.cyclic_subideal_p1
   1 of   8 in sage.schemes.elliptic_curves.heegner.HeegnerQuatAlg.kolyvagin_cyclic_subideals
   1 of   2 in sage.schemes.elliptic_curves.heegner.HeegnerQuatAlg.right_ideals
    [1110 tests, 3 failures, 36.95 s]
----------------------------------------------------------------------
sage -t --warn-long 65.7 --random-seed=172242929068586131357270719533848860749 src/sage/schemes/elliptic_curves/heegner.py  # 3 doctests failed
----------------------------------------------------------------------
sage -t --warn-long 65.7 --random-seed=172242929068586131357270719533848860749 src/sage/modular/quatalg/brandt.py
**********************************************************************
File "src/sage/modular/quatalg/brandt.py", line 142, in sage.modular.quatalg.brandt
Failed example:
    B.right_ideals()
Expected:
    (Fractional ideal (2 + 2*j, 2*i + 2*k, 4*j, 4*k), Fractional ideal (2 + 2*j, 2*i + 6*k, 8*j, 8*k), Fractional ideal (2 + 10*j + 8*k, 2*i + 8*j + 6*k, 16*j, 16*k))
Got:
    (Fractional ideal (4, 4*i, 2 + 2*j, 2*i + 2*k),
     Fractional ideal (8, 8*i, 2 + 2*j, 6*i + 2*k),
     Fractional ideal (16, 16*i, 10 + 8*i + 2*j, 8 + 6*i + 2*k))
**********************************************************************
File "src/sage/modular/quatalg/brandt.py", line 805, in sage.modular.quatalg.brandt.BrandtModule_class.cyclic_submodules
Failed example:
    B.cyclic_submodules(I, 2)
Expected:
    [Fractional ideal (1/2 + 3/2*j + k, 1/2*i + j + 1/2*k, 2*j, 2*k),
     Fractional ideal (1/2 + 1/2*i + 1/2*j + 1/2*k, i + k, j + k, 2*k),
     Fractional ideal (1/2 + 1/2*j + k, 1/2*i + j + 3/2*k, 2*j, 2*k)]
Got:
    [Fractional ideal (2, 2*i, 3/2 + i + 1/2*j, 1 + 1/2*i + 1/2*k),
     Fractional ideal (2, 1 + i, 1 + j, 1/2 + 1/2*i + 1/2*j + 1/2*k),
     Fractional ideal (2, 2*i, 1/2 + i + 1/2*j, 1 + 3/2*i + 1/2*k)]
**********************************************************************
File "src/sage/modular/quatalg/brandt.py", line 809, in sage.modular.quatalg.brandt.BrandtModule_class.cyclic_submodules
Failed example:
    B.cyclic_submodules(I, 3)
Expected:
    [Fractional ideal (1/2 + 1/2*j, 1/2*i + 5/2*k, 3*j, 3*k),
     Fractional ideal (1/2 + 3/2*j + 2*k, 1/2*i + 2*j + 3/2*k, 3*j, 3*k),
     Fractional ideal (1/2 + 3/2*j + k, 1/2*i + j + 3/2*k, 3*j, 3*k),
     Fractional ideal (1/2 + 5/2*j, 1/2*i + 1/2*k, 3*j, 3*k)]
Got:
    [Fractional ideal (3, 3*i, 1/2 + 1/2*j, 5/2*i + 1/2*k),
     Fractional ideal (3, 3*i, 3/2 + 2*i + 1/2*j, 2 + 3/2*i + 1/2*k),
     Fractional ideal (3, 3*i, 3/2 + i + 1/2*j, 1 + 3/2*i + 1/2*k),
     Fractional ideal (3, 3*i, 5/2 + 1/2*j, 1/2*i + 1/2*k)]
**********************************************************************
File "src/sage/modular/quatalg/brandt.py", line 1254, in sage.modular.quatalg.brandt.BrandtModule_class.right_ideals
Failed example:
    B.right_ideals()
Expected:
    (Fractional ideal (2 + 2*j, 2*i + 2*k, 4*j, 4*k),
     Fractional ideal (2 + 2*j, 2*i + 6*k, 8*j, 8*k),
     Fractional ideal (2 + 10*j + 8*k, 2*i + 8*j + 6*k, 16*j, 16*k))
Got:
    (Fractional ideal (4, 4*i, 2 + 2*j, 2*i + 2*k),
     Fractional ideal (8, 8*i, 2 + 2*j, 6*i + 2*k),
     Fractional ideal (16, 16*i, 10 + 8*i + 2*j, 8 + 6*i + 2*k))
**********************************************************************
3 items had failures:
   1 of  14 in sage.modular.quatalg.brandt
   2 of   6 in sage.modular.quatalg.brandt.BrandtModule_class.cyclic_submodules
   1 of   7 in sage.modular.quatalg.brandt.BrandtModule_class.right_ideals
    [165 tests, 4 failures, 4.34 s]
----------------------------------------------------------------------
sage -t --warn-long 65.7 --random-seed=172242929068586131357270719533848860749 src/sage/modular/quatalg/brandt.py  # 4 doctests failed
----------------------------------------------------------------------

Copy link
Collaborator

@kwankyu kwankyu left a comment

Choose a reason for hiding this comment

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

Thanks. LGTM.

@yyyyx4
Copy link
Member Author

yyyyx4 commented Aug 11, 2024

Thank you!

vbraun pushed a commit to vbraun/sage that referenced this pull request Aug 27, 2024
…_lattice()

    
Fixes sagemath#34880.
    
URL: sagemath#34962
Reported by: Lorenz Panny
Reviewer(s): Kwankyu Lee
@vbraun vbraun merged commit 28ee8ab into sagemath:develop Sep 3, 2024
18 of 20 checks passed
@yyyyx4 yyyyx4 deleted the public/reverse_by_default_in_basis_for_quaternion_lattice branch September 3, 2024 22:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

set reverse=True by default in basis_for_quaternion_lattice()
4 participants