Re: Physical constants in IDL with !CONST [message #82593 is a reply to message #82525] |
Wed, 19 December 2012 21:37   |
chris_torrence@NOSPAM
Messages: 528 Registered: March 2007
|
Senior Member |
|
|
On Wednesday, December 19, 2012 9:43:16 PM UTC-7, Craig Markwardt wrote:
> On Wednesday, December 19, 2012 10:36:24 PM UTC-5, Jeff N. wrote:
>
>> Chris,
>
>>
>
>>
>
>>
>
>> If you're going to put pi in there, which we already have in !pi, you might also consider putting !dtor and !radeg in as well, otherwise people might be wondering why !pi was put into !const but not the other two.
>
>
>
> But if you do, then put the double precision values! !DTOR is worse than useless for me because it's only single precision.
>
>
>
> Craig
Hi all,
These are great suggestions.
Paul, I just added in all of your constants except "c1" and "c2". There seems to be a discrepancy with the definition of c1. NIST gives it as 2.pi.h.c^2, which is a factor of "pi" bigger than your constant. I don't want anyone to get confused and just use the constant blindly, perhaps including an unexpected extra factor of pi. Which one is in "standard" use?
Craig, I'll add in the AU, and the mass of the Sun & Earth. And of course "dtor" and "radeg" (double precision!). But don't worry, the older system variables won't go away.
Russell, great suggestion on including more info, like the "units". I'd love to do that, but I don't want to make the structure too complicated. What about having a second system variable, say something like !CONST_UNITS, which could contain additional information?
-Chris
|
|
|