# [LON-CAPA-users] formula response and maxima floating point numbers

**Lon H Mitchell
**
lon-capa-users@mail.lon-capa.org

*Thu, 09 Sep 2010 09:54:13 -0400*

According to the Maxima manual, a shortcut to getting a floating point
approximation to a function value is to use a decimal argument. For
example, sqrt(2.0) will return 1.414213562373095 while sqrt(2) will stay
as sqrt(2).
This shortcut can result in some seemingly incomprehensible answers.
For example, "is(sqrt(1.5) = sqrt(3/2))" returns /false/. Further, a
formula response problem with answer "1+ sqrt(3/2)*x" will mark "1 +
sqrt(1.5)*x" as incorrect and vice versa. Since the behavior is
inherent to Maxima, math response problems can be similarly affected.
Note that this behavior only seems to arise when dealing with a function
value. For example, "x^(1.5)" and "x^(3/2)" are considered equivalent
by Maxima, as are "1.5" and "3/2".
While one possible solution is to use sampling rather than algebraic
checking, my guess would be that sqrt(1.5) = sqrt(3/2) would be an
expected equivalence on the part of most users.
The question then: is there a way to instruct Maxima to turn this
shortcut behavior off, and, if so, is it possible to change formula
response problems (or lonmaxima) to make use of it?
Thanks,
Lon Mitchell