id	summary	reporter	owner	description	type	status	priority	milestone	component	resolution	keywords	cc	work_issues	upstream	reviewer	author	merged	dependencies	stopgaps
9869	finite field bug	mariah	AlexGhitza	"{{{
# Demonstrate a finite field bug in which
# a product of nonzero elements is equal to 0 
# (which should not happen in a field)
#
# This is the smallest example I could find. It seems salient that
# the square of p is bigger than a 32-bit C integer. Larger values
# for p also exhibit the bug, smaller ones do not.

p = 2^16 + 1

# Create a quadratic field extension
K.<alpha> = GF(p^2)

# Choose some non-zero element of K, use the random_element
# method.
x = K(0)
while x == K(0):
  x = K.random_element()

K.<alpha> = GF(p^2)  # this line is necessary for bug
x_coerce = K(x)
print 2*x_coerce  # prints zero
}}}
"	defect	closed	major	sage-duplicate/invalid/wontfix	basic arithmetic	duplicate				N/A		Mariah Lenox			
