From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,9d303864ae4c70ad X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2004-04-12 23:52:41 PST Path: archiver1.google.com!postnews1.google.com!not-for-mail From: 18k11tm001@sneakemail.com (Russ) Newsgroups: comp.lang.ada Subject: Re: Expressing physical units (Was: Reprise: 'in out' parameters for functions) Date: 12 Apr 2004 23:52:40 -0700 Organization: http://groups.google.com Message-ID: References: <5ad0dd8a.0404090512.15af2908@posting.google.com> <5ad0dd8a.0404100507.729d3577@posting.google.com> NNTP-Posting-Host: 63.194.87.148 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Trace: posting.google.com 1081839161 29040 127.0.0.1 (13 Apr 2004 06:52:41 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Tue, 13 Apr 2004 06:52:41 +0000 (UTC) Xref: archiver1.google.com comp.lang.ada:7031 Date: 2004-04-12T23:52:40-07:00 List-Id: "Dmitry A. Kazakov" wrote in message news:... > Russ wrote: > > > By the way, I work in the field of air traffic management (ATM), and > > I'd really like to see a practical way to guarantee units consistency. > > The general mks system is inappropriate for ATM. The traditional units > > for ATM are nautical miles (nmi) for horizontal length, and feet (ft) > > for altitude. That won't change in our lifetimes -- and probably > > never. As for time, it can be in seconds, minutes, or hours. > > Horizontal speed in usually given in terms of knots (kn), which is > > nmi/hr, but altitude rate is usually given in terms of ft/min. Heading > > is normally given in degrees. > > > > In my experience, the most common units problem is confusion between > > degrees and radians. Radians are preferable for use inside programs, > > but degrees are preferable for I/O. This problem really needs to be > > licked once and for all. > > It does not differ from [m] vs. [ft]. The dimension of radian is [1] = > m**0*A**0*s**0... The dimension of degree is [Pi/180]. No magic here. More > difficult is Celsius degree vs. K, which AFAIK cannot be solved using C++ > templates. I know it can be done in C++, but I thought we were talking about doing it in Ada. By the way, what the heck is "m**0*A**0*s**0..."? > > The next most common problem I find is that > > altitude is alternately expressed in terms of ft, hundreds of ft, or > > thousands of feet. Standard "Flight Levels" are at multiples of 1000 > > ft, but they are expressed in units of 100 ft. For example, "FL310" is > > a pressure altitude of 31,000 ft. > > See above.