• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Scientific notation
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Scientific notation


  • Subject: Re: Scientific notation
  • From: John Delacour <email@hidden>
  • Date: Fri, 2 May 2003 18:29:17 +0100
  • Mac-eudora-version: 6.0a16

At 8:24 pm -0400 1/5/03, Steve Roy wrote:

In a script, I'm getting small real numbers such as 3.0E-4. When I turn them to
string, I would like them to appear in normal notation "0.0003" instead of
"3.0E-4". Is that possible?


It depends how small your number is. Using perl, the limit is 1/10000 before it switches to scientific, and there's almost certainly a simple trick to go beyond that, which no doubt someone else knows.


set numb to 1 / 9999.9
set n to "1 / 9999.9"
set np to do shell script "perl -e 'print " & n & "'"
{numb, np}
--> {1.0000100001E-4, "0.00010000100001"}

JD
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: Scientific notation
      • From: Doug McNutt <email@hidden>
  • Prev by Date: Re: mac to unix path names
  • Next by Date: Re: Scientific notation
  • Previous by thread: Re: Scientific notation
  • Next by thread: Re: Scientific notation
  • Index(es):
    • Date
    • Thread