Skip to content
This repository has been archived by the owner on Jan 30, 2023. It is now read-only.

Commit

Permalink
Added doctest from Kevin Buzzard via sage-nt
Browse files Browse the repository at this point in the history
  • Loading branch information
kedlaya committed May 5, 2016
1 parent db39004 commit fa9c485
Showing 1 changed file with 32 additions and 0 deletions.
32 changes: 32 additions & 0 deletions src/sage/rings/number_field/number_field.py
Expand Up @@ -2794,6 +2794,38 @@ def __hash__(self):
[(alpha, 1), ((-omega - 1)*alpha, 1), (omega*alpha, 1)]
[(alpha, 1), (omega*alpha, 1), ((-omega - 1)*alpha, 1)]
This example was suggested on sage-nt; see :trac:`18942`::
sage: G=DirichletGroup(80);
sage: for chi in G:
....: D=ModularSymbols(chi,2,-1).cuspidal_subspace().new_subspace().decomposition()
....: for f in D:
....: elt=f.q_eigenform(10,'alpha')[3];
....: print(elt.is_integral())
True
True
True
True
True
True
True
True
True
True
True
True
True
True
True
True
True
True
True
True
True
True
True
"""
return hash((self.variable_name(), self.base_field(), tuple(self.__relative_polynomial)))

Expand Down

0 comments on commit fa9c485

Please sign in to comment.