octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

format short output with small numbers (bug #56936)


From: Rik
Subject: format short output with small numbers (bug #56936)
Date: Mon, 23 Sep 2019 15:14:40 -0700

All,

What should happen when we display small numbers with "format short"
(default)?  Should we end up printing a lot of zeros?  That is what happens
now.

x = [-pi;0;pi];
x*1e-6
ans =

  -0.0000031416
              0
   0.0000031416

In earlier Octave versions we would switch over to scientific notation at a
certain point.  These are the results from version 3.4.3

octave-3.4.3:5> x*1e-3
ans =

  -0.0031416
   0.0000000
   0.0031416

octave-3.4.3:6> x*1e-4
ans =

  -3.1416e-04
   0.0000e+00
   3.1416e-04

--Rik




reply via email to

[Prev in Thread] Current Thread [Next in Thread]