Martin Rubey wrote:
> Dear Gaby & Waldek,
>
> as you may know, there is a problem fixing bug #354, Complex R is not
> necessarily a field when R is a field.
>
> It would be quite straightforward to fix it, if we could conditionally export
> Field, depending on a Boolean valued function, like
>
> if R has Field and R has Finite and size()$R rem 4 = 1 then Field
>
> Currently, spad seems to accept statements of the form
>
> D has C
>
> and
>
> D1 is d2
>
> only. (Please check this, I'm not entirely sure.) Do you think it would be
> difficult to fix this? I do not see a workaround, unfortunately.
>
For issue 354 I belive that there is reasonable workaround: just export
Field unconditionally (as we do know), but throw error when sombody
tries to create a fake field. For example PrimeField is doing this --
it exports Field for any value of p, but complains if you give it
non-prime p.
I belive that we should add to Complex something like the snippet below
(untested, ATM I am busy with other things)
== add
if R has Field then
if R has complex or _
((characteristic()$R) mod 5 = 1) or _
(R has Finite and _
((size()$R) mod 5 = 1) then
error "Field given to Complex already contains square root of -1"
--
Waldek Hebisch
[EMAIL PROTECTED]
_______________________________________________
Axiom-developer mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/axiom-developer