Printing Float

5 views
Skip to first unread message

Waldek Hebisch

unread,
May 18, 2012, 1:22:24 PM5/18/12
to fricas...@googlegroups.com
I would like to separate blocks of digits in Float using underscores
(as opposed to blanks). That is `exp(2.0)' would give:

7.3890560989_306502272

instead of

7.3890560989 306502272

The main reason is to make FriCAS output closer to its input,
but also I think that with undercores is is clearer that
what is printed is a single number and not several.

I would prefer just to change separator character, but if
somebody really like or depend on blanks we could make
the separator settable.

Opinions?

--
Waldek Hebisch
heb...@math.uni.wroc.pl

Ralf Hemmecke

unread,
May 18, 2012, 3:17:09 PM5/18/12
to fricas...@googlegroups.com
> 7.3890560989_306502272
>
> instead of
>
> 7.3890560989 306502272

Underscore is OK and also preferable, because it allows paste output as
input.

> I would prefer just to change separator character, but if
> somebody really like or depend on blanks we could make
> the separator settable.

I've no clear opinion on this. In fact, for me it would also be OK to
replaces " " by "", i.e. remove the space completely.

Ralf

Waldek Hebisch

unread,
May 19, 2012, 11:25:48 AM5/19/12
to fricas...@googlegroups.com
That is actually settable now, see 'outputSpacing' in Float
(with parameter 0 it supresses separator).

--
Waldek Hebisch
heb...@math.uni.wroc.pl
Reply all
Reply to author
Forward
0 new messages