Path: news.mathworks.com!not-for-mail
From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Re: How do I increase the precision of MATLAB?
Date: Sun, 11 Jan 2009 00:43:02 +0000 (UTC)
Organization: The MathWorks, Inc.
Lines: 29
Message-ID: <gkbfam$sa0$1@fred.mathworks.com>
References: <gkb7mu$4r$1@fred.mathworks.com>
Reply-To: <HIDDEN>
NNTP-Posting-Host: webapp-03-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1231634582 28992 172.30.248.38 (11 Jan 2009 00:43:02 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Sun, 11 Jan 2009 00:43:02 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 870136
Xref: news.mathworks.com comp.soft-sys.matlab:510808


Hello Thiago:
You are not looking for higher precision: you need more integers in the exponent!
Yours is a huge number; exp(709) is the largest that fit into the IEEE double precision format. You are requiring nearly the triple of the exponent, implying nearly the cube of the largest representable number. Maybe you want to manipulate your exponent some way to produce something interpretable...
Anyhow, try the MPTOOLBOX by Ben Barrowes, available in the FEX. I am not shure if it could provide a solution, but...
Regards
Carlos

"Thiago " <thiago@mathworks.com> wrote in message <gkb7mu$4r$1@fred.mathworks.com>...
> Folks,
> 
> Simple question.  How do I increase the precision of MATLAB, if that is possible by any means? I'm trying to calculate this:
> 
> ----------------------------------------------------------------------------------------------
> >> z
> 
> z =
> 
>      2.225167162095353e+003 -9.020383145678592e+002i
> 
> >> exp( i*z )
> 
> ans =
> 
>                Inf +              Infi
> ----------------------------------------------------------------------------------------------
> 
> Yes, I know that exponentials grow fast, but I'd like to find an exact number.
> 
> Thanks