More consistent handling of 4.0*x - 3.0*x



another choice would be to say float(x) --> error,  x is not a number.
and have another program
convert_number_to_float_else_leave_alone(x)  -->  x
and perhaps a third, which inserts "float" around things that are not 
explicitly floats.
float(x) --> 'float(x).

I think it is a mistake to do   bfloat(3*x) -->  3.0b0*bfloat(x).

Is bfloat(x^2) ->  bfloat(x)^(2.0b0) ?   now it is x^2.  or would you 
like bfloat(x)^2 ??
note

bfloat(exp(2*x)  is exp(2.0b0*x)

Also, if you do this:
fpprec:100$
z:bfloat(x);  --> bfloat(x)

fpprec:25;

x:%pi;
ev(z)

do you get 100 digits of pi, because that is what fpprec indicates when 
z was created, or
25 digits, because that is what was set when z was evaluated...
:)

I suggest looking at what Mathematica does.

RJF

Robert Dodier wrote:
> OK by me, but while we're at it, I think float(x) should
> yield 'float(x) instead of just x, likewise for bfloat(x).
>
> (If we're going to the trouble to make (literal float)*variable
> work correctly with lazy evaluation, we should do
> the same for float(variable).)
>
> best
>
> Robert Dodier
> _______________________________________________
> Maxima mailing list
> Maxima at math.utexas.edu
> http://www.math.utexas.edu/mailman/listinfo/maxima
>