Opened 11 years ago

Closed 11 years ago

Last modified 11 years ago

#9666 closed enhancement (duplicate)

Implement __hash__ for NumberFieldIdeal

Reported by: jdemeyer Owned by: davidloeffler
Priority: minor Milestone: sage-duplicate/invalid/wontfix
Component: number fields Keywords:
Cc: Merged in:
Authors: Jeroen Demeyer Reviewers:
Report Upstream: N/A Work issues:
Branch: Commit:
Dependencies: Stopgaps:

Status badges


I propose to use a HNF Z-basis of number field ideals to compute the hash of an ideal.

Attachments (1)

9666.patch (893 bytes) - added by jdemeyer 11 years ago.

Download all attachments as: .zip

Change History (8)

Changed 11 years ago by jdemeyer

comment:1 Changed 11 years ago by jdemeyer

  • Status changed from new to needs_review

comment:2 Changed 11 years ago by jdemeyer

  • Status changed from needs_review to needs_work

comment:3 Changed 11 years ago by was

You need to add a doctest that illustrates use of the hash function, on both 32 and 64-bit computers.

comment:4 Changed 11 years ago by was

When I ran the test suite there were a bunch of failures in



File "/mnt/usb1/scratch/wstein/build/sage-4.5.2.rc0/devel/sage/sage/rings/polynomial/", line 1141:
    sage: D.selmer_group([K.ideal(2, -a+1), K.ideal(3, a+1), K.ideal(a)], 3)
    [2, -a - 1, -a]
    [2, -a - 1, a]

comment:5 Changed 11 years ago by jdemeyer

  • Milestone changed from sage-4.5.3 to sage-4.6

Apologies. I did not expect the hash to have influence on this, I should have tested better.

I will postpone this to the release after the PARI upgrade, i.e. sage-4.6.1 or something.

comment:6 Changed 11 years ago by was

  • Resolution set to duplicate
  • Status changed from needs_work to closed

The same is fixed correctly in #9400. So I'm closing this as a dupe of that.

comment:7 Changed 11 years ago by mvngu

  • Milestone changed from sage-4.6 to sage-duplicate/invalid/wontfix
Note: See TracTickets for help on using tickets.