Opened 4 years ago

Closed 3 years ago

#25780 closed defect (fixed)

Normalize bound checking in points function

Reported by: raghukul01 Owned by:
Priority: major Milestone: sage-8.3
Component: algebraic geometry Keywords: algebraic scheme, gsoc2018
Cc: bhutz, raghukul01 Merged in:
Authors: Raghukul Raman Reviewers: Ben Hutz
Report Upstream: N/A Work issues:
Branch: b9266c6 (Commits, GitHub, GitLab) Commit: b9266c657e20c8832e043bddd24d1abace89dc5a
Dependencies: Stopgaps:

Status badges

Description

Consider this example

sage: P.<x,y> = ProjectiveSpace(QQ, 1)
sage: print sorted(list(P.points_of_bounded_height(bound=3)))
[(-2 : 1), (-1 : 1), (-1/2 : 1), (0 : 1), (1/2 : 1), (1 : 0), (1 : 1), (2 : 1)]

Points of height 3 are not present.

sage: P.<x,y,z> = ProjectiveSpace(2,QQ)
sage: list(P.points_of_bounded_height(bound=5))

here we have some points like (2 : -4/3 : 1) which have height=6, if we use enum_projective_rational_field function results are as we would expect. So the underlying definition for height of rational points need to be uniform in all these functions.

Change History (6)

comment:1 Changed 4 years ago by raghukul01

  • Branch set to u/raghukul01/normalize_bound_checking_in_points_function

comment:2 Changed 4 years ago by raghukul01

  • Authors set to Raghukul Raman
  • Commit set to 26c28949343ffa6dc2d1ba1e142fe4a28d312543
  • Status changed from new to needs_review

New commits:

26c289425780: Corrected algorithm in points function

comment:3 Changed 4 years ago by bhutz

Just one comment here. What do you think about using?

self.point(c, check=False)

It is about twice as fast and since the function is for projective space (not a subscheme) it's not like we need to check that the point is well-defined. It will cause them not to be normalized to the last coordinate to 1 though.

I have the doctests running now, but I don't really expect a failure.

comment:4 Changed 4 years ago by git

  • Commit changed from 26c28949343ffa6dc2d1ba1e142fe4a28d312543 to b9266c657e20c8832e043bddd24d1abace89dc5a

Branch pushed to git repo; I updated commit sha1. New commits:

b9266c625780: Improved conversion to projective point

comment:5 Changed 4 years ago by bhutz

  • Reviewers set to Ben Hutz
  • Status changed from needs_review to positive_review

comment:6 Changed 3 years ago by vbraun

  • Branch changed from u/raghukul01/normalize_bound_checking_in_points_function to b9266c657e20c8832e043bddd24d1abace89dc5a
  • Resolution set to fixed
  • Status changed from positive_review to closed
Note: See TracTickets for help on using tickets.