Calculus with Matlab or octave
Ben Abbott
bpabbott at mac.com
Fri May 9 19:19:40 CDT 2008
On May 9, 2008, at 7:39 PM, hassen62 at voila.fr wrote:
> Dear friends,
>
> when we make some simple calculus with Octave or Matlab, how to have
> precise results in more than 4 decimal numbers.
>
> example:2.9014567*8.9665531;#the result in Octave prompt is
>
> ans=26.016
>
> I would like to obtain a result with also six decimal figures and
> not three(016).
>
> Thank you very much
>
Its not exactly "Calculus", but if you want more precision ...
> x = 2.9014567*8.9665531;
> num2str (x, "%16.12g")
Ben
More information about the Help-octave
mailing list