login  home  contents  what's new  discussion  bug reports     help  links  subscribe  changes  refresh  edit

Edit detail for #299 MachineFloat is not a FIeld revision 1 of 2

1 2
Editor:
Time: 2007/11/17 22:23:08 GMT-8
Note: Axiom is not very strict...

changed:
-
\begin{axiom}
F := MachineFloat
a: F := -0.12345
b: F := -1234567890.0
c: F := 1234567890.12345
(a+b)+c
a+(b+c)
F has Field
\end{axiom}
MachineFloat clearly doesn't form a (mathematical) field as the above code demonstrates (and we all know).

From greg Thu Jun 22 09:18:32 -0500 2006
From: greg
Date: Thu, 22 Jun 2006 09:18:32 -0500
Subject: DoubleFloat and Float too
Message-ID: <20060622091832-0500@wiki.axiom-developer.org>

\begin{axiom}
)cl all
F := Float
digits()
a: F := -0.12345
b: F := -1234567890.0
c: F := 1234567890.12345
(a+b)+c
a+(b+c)
F has Field
\end{axiom}

From kratt6 Thu Jun 22 09:39:26 -0500 2006
From: kratt6
Date: Thu, 22 Jun 2006 09:39:26 -0500
Subject: Axiom is not very strict...
Message-ID: <20060622093926-0500@wiki.axiom-developer.org>

Unfortunately, Axiom is not very strict with these things, although it should be, I believe. Some examples:

* in Axiom, every field has the attribute 'canonicalUnitNormal'.

In ATTREG.SPAD, we find::

  canonicalUnitNormal
    ++ \spad{canonicalUnitNormal} is true if we can choose a canonical
    ++ representative for each class of associate elements, that is
    ++ \spad{associates?(a,b)} returns true if and only if 
    ++ \spad{unitCanonical(a) = unitCanonical(b)}.

However, I suspect, this cannot be done in every field. 

* the domain 'EXPR' is a field, although it is (I think) meant to allow arbitrary functions to be expressed, for example $\chi(x<0)$, which does not have an inverse, I'd say.

In the documentation of MuPAD, they say that (their) expression domain is a field for "convenience". Maybe this is related to the above.

In any case, we certainly cannot decide whether an element is zero or not.


Martin


Submitted by : (unknown) at: 2007-11-17T22:23:08-08:00 (19 years ago)
Name :
Axiom Version :
Category : Severity : Status :
Optional subject :  
Optional comment :

fricas
(1) -> F := MachineFloat

\label{eq1}\hbox{\axiomType{MachineFloat}\ }(1)
Type: Type
fricas
a: F := -0.12345

\label{eq2}-{0.12345}(2)
Type: MachineFloat?
fricas
b: F := -1234567890.0

\label{eq3}-{1234567890.0}(3)
Type: MachineFloat?
fricas
c: F := 1234567890.12345

\label{eq4}1234567890.12345(4)
Type: MachineFloat?
fricas
(a+b)+c

\label{eq5}-{0.2384185791 \<u> 015625 E - 6}(5)
Type: MachineFloat?
fricas
a+(b+c)

\label{eq6}-{0.1976013183 \<u> 496717 E - 6}(6)
Type: MachineFloat?
fricas
F has Field

\label{eq7} \mbox{\rm true} (7)
Type: Boolean

MachineFloat? clearly doesn't form a (mathematical) field as the above code demonstrates (and we all know).

DoubleFloat? and Float too --greg, Thu, 22 Jun 2006 09:18:32 -0500 reply
fricas
)cl all
All user variables and function definitions have been cleared. F := Float

\label{eq8}\hbox{\axiomType{Float}\ }(8)
Type: Type
fricas
digits()

\label{eq9}20(9)
Type: PositiveInteger?
fricas
a: F := -0.12345

\label{eq10}-{0.12345}(10)
Type: Float
fricas
b: F := -1234567890.0

\label{eq11}-{1234567890.0}(11)
Type: Float
fricas
c: F := 1234567890.12345

\label{eq12}1234567890.12345(12)
Type: Float
fricas
(a+b)+c

\label{eq13}0.0(13)
Type: Float
fricas
a+(b+c)

\label{eq14}-{0.861473381 E - 12}(14)
Type: Float
fricas
F has Field

\label{eq15} \mbox{\rm true} (15)
Type: Boolean

Axiom is not very strict... --kratt6, Thu, 22 Jun 2006 09:39:26 -0500 reply
Unfortunately, Axiom is not very strict with these things, although it should be, I believe. Some examples:

  • in Axiom, every field has the attribute canonicalUnitNormal.

In ATTREG.SPAD, we find:

  canonicalUnitNormal
    ++ \spad{canonicalUnitNormal} is true if we can choose a canonical
    ++ representative for each class of associate elements, that is
    ++ \spad{associates?(a,b)} returns true if and only if 
    ++ \spad{unitCanonical(a) = unitCanonical(b)}.

However, I suspect, this cannot be done in every field.

  • the domain EXPR is a field, although it is (I think) meant to allow arbitrary functions to be expressed, for example \chi(x<0), which does not have an inverse, I'd say.

In the documentation of MuPAD?, they say that (their) expression domain is a field for "convenience". Maybe this is related to the above.

In any case, we certainly cannot decide whether an element is zero or not.

Martin