RE: N[ ] function problem
- To: mathgroup at smc.vnet.net
- Subject: [mg41627] RE: [mg41607] N[ ] function problem
- From: "David Park" <djmp at earthlink.net>
- Date: Thu, 29 May 2003 08:13:52 -0400 (EDT)
- Sender: owner-wri-mathgroup at wolfram.com
Warren, This is a frequent question. The purpose of N is to convert exact numbers (such as Pi or Sqrt[2]) to approximate numbers. Its purpose is not to format the number. To format an approximate number for display use NumberForm or ScientificForm or EngineeringForm. And check out their options. Approximate numbers in machine precision are displayed with 6 places (but stored internally with 16 places). You can change the display with the option inspector. If the number is an arbitrary precision approximate number (more than machine precision), then it displays with full precision. Machine precision numbers use the floating point hardware of your processor. Arbitrary precision numbers use software. Check out Section 3.1 in The Mathematica Book. David Park djmp at earthlink.net http://home.earthlink.net/~djmp/ From: Warren Wolfe [mailto:wwolfe18 at attbi.com] To: mathgroup at smc.vnet.net I have found that the N[expr, n] function always returns 6 digits for n < 17. Above 17 it works as advertised. I am using version 4.2 on a Windows 98 machine. I did not have this problem with version 3.0 on this machine. Can anyone give me a clue what's happening? Warren Wolfe