comp.lang.ada
 help / color / mirror / Atom feed
From: "Marin David Condic" <dont.bother.mcondic.auntie.spam@[acm.org>
Subject: Re: Math Libraries (was Re: Ada2005)
Date: Thu, 20 Dec 2001 15:34:33 -0500
Date: 2001-12-20T20:34:35+00:00	[thread overview]
Message-ID: <9vti0r$jrj$1@nh.pace.co.uk> (raw)
In-Reply-To: 3C22468C.30901@look.ca

I could see that objection, but it still seems that it would be nice to have
something like this available for other numeric types. Personally, I'd be
willing to live with the possibility that for a number of particularly small
fixed or decimal types, the computations might generate Constraint_Error so
long as for the ones that were big enough I got a result. Its up to the user
to define types of sufficient size and precision to have something like Sqrt
make sense for it.

Clearly, the original package was intended to line up nicely with hardware
or OS supplied libraries and I see no reason that it should change. I'm
thinking along the lines of extention in other packages that might have to
do their computation strictly in the Ada language. It might not even need to
be under Ada.Numerics.

I might not object if the underlying implementation did conversions to some
floating point type and converted the result back to whatever it had to.
Sure, I could do it myself, but having things like Log and Sqrt available
for fixed and decimal types seems almost as fundamental as having "+" and
"-". Its pretty basic to most math that is just a bit more complex than
balancing my checkbook. (Maybe even there as well - you need Sqrt to compute
interest, don't you? :-)

You're probably right about it being considered and rejected for Ada95.
Maybe its time to reconsider?

Other extensions I think would be useful here would be vector and matrix
math. That shows up often enough to be generally useful and there are
already a number of packages available to do it. So it could be a case of
standardizing on an existing library - if I dare bring that up! :-)

I'd also vote for statistics - partly because I think it would get used a
lot and partly because I just like statistics. (A friend once described it
this way: Statistics is to Math what The National Enquirer is to Journalism.
:-)

Other languages provide some math capabilities, but generally don't go this
far. That would make Ada even more useful in the math realm than it already
is. And I don't think its a stretch too far from the beaten path to cover
vectors, matricese and statistics. Those areas are used often enough that it
wouldn't seem "strange" to support them.

MDC
--
Marin David Condic
Senior Software Engineer
Pace Micro Technology Americas    www.pacemicro.com
Enabling the digital revolution
e-Mail:    marin.condic@pacemicro.com
Web:      http://www.mcondic.com/


"FGD" <presbeis@look.ca> wrote in message news:3C22468C.30901@look.ca...
>
>
> There is a range issue here, most of these functions will map out of the
> range of the original type or will have unsatisfactory precision within
> the original type--such extensions are generally useless. Converting to
> float and using the float result is usually the best solution. For most
> of the remaining cases converting back from float to the original type
> is the most efficient way to compute the desired result. For the very
> few remaining cases, the programer should be able to supply efficient
> algorithms.
>
> I think all of this was considered when designing Ada95.
>






  reply	other threads:[~2001-12-20 20:34 UTC|newest]

Thread overview: 71+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-12-11  9:33 Ada2005 Peter Hermann
2001-12-11 11:05 ` Ada2005 M. A. Alves
2001-12-11 11:55   ` Ada2005 Aaro Koskinen
2001-12-11 14:49     ` Ada2005 Wes Groleau
2001-12-11 14:58     ` Ada2005 Marin David Condic
2001-12-11 15:18       ` Ada2005 Ted Dennison
2001-12-12  8:37       ` Ada2005 Alfred Hilscher
2001-12-11 11:23 ` Ada2005 Martin Dowie
2001-12-11 11:54 ` Ada2005 Preben Randhol
2001-12-11 12:06 ` Ada2005 Larry Kilgallen
2001-12-11 14:39 ` Ada2005 Ted Dennison
2001-12-12  4:39   ` Ada2005 Jeffrey Carter
2001-12-13 18:39   ` Ada2005 Randy Brukardt
2001-12-12 11:29 ` Ada2005 Peter Hermann
2001-12-12 12:42   ` Ada2005 Larry Kilgallen
2001-12-12 12:51   ` Ada2005 Martin Dowie
2001-12-12 12:59   ` Ada2005 Carsten Freining
2001-12-12 14:40     ` Ada2005 Peter Hermann
2001-12-12 15:16       ` Ada2005 Ted Dennison
2001-12-12 15:37         ` Ada2005 Larry Kilgallen
2001-12-12 17:49           ` Ada2005 Ted Dennison
2001-12-12 18:02         ` Ada2005 tmoran
2001-12-12 18:17           ` Ada2005 Ted Dennison
2001-12-12 18:31             ` Ada2005 Sergey Koshcheyev
2001-12-12 19:08               ` Ada2005 Ted Dennison
2001-12-12 18:14         ` Ada2005 Mark Lundquist
2001-12-12 18:40           ` Ada2005 Ted Dennison
2001-12-12 19:12             ` Ada2005 Mark Lundquist
2001-12-12 19:41               ` Ada2005 Ted Dennison
2001-12-13 20:07         ` Ada2005 Ted Dennison
2001-12-14  4:40       ` Ada2005 Patrick Hohmeyer
2001-12-14  9:55         ` Ada2005 Lutz Donnerhacke
2001-12-14 10:36         ` Ada2005 Dmitry A. Kazakov
2001-12-17 18:40         ` Ada2005 Matthew Heaney
2001-12-12 18:04     ` Ada2005 Mark Lundquist
2001-12-12 21:25       ` Ada2005 Mark Lundquist
2001-12-13 18:40         ` Ada2005 Stephen Leake
2001-12-13 19:01           ` Ada2005 Mark Lundquist
2001-12-14 17:17             ` Ada2005 Stephen Leake
2001-12-13  9:11       ` Ada2005 Dmitry A. Kazakov
2001-12-17 17:50         ` Ada2005 Ray Blaak
2001-12-18 11:55           ` Ada2005 Dmitry A. Kazakov
2001-12-18 19:51             ` Ada2005 Ray Blaak
2001-12-19  8:34               ` Ada2005 Dmitry A. Kazakov
2001-12-19 13:30                 ` Ada2005 Mark Lundquist
2001-12-19 18:23                 ` Ada2005 Ray Blaak
2001-12-19 18:20           ` Ada2005 Mark Lundquist
2001-12-19 19:19             ` Ada2005 Ray Blaak
2001-12-20 14:17             ` Ada2005 Dmitry A. Kazakov
2001-12-20 11:24       ` Ada2005 Carsten Freining
2001-12-20 14:27         ` Ada2005 Mark Lundquist
2001-12-20 15:01         ` Ada2005 Matthew Woodcraft
2001-12-20 15:45         ` Ada2005 Mark Lundquist
2001-12-20 16:20           ` Ada2005 Mark Lundquist
2001-12-13 18:13     ` Ada2005 Georg Bauhaus
2001-12-20 16:34 ` Math Libraries (was Re: Ada2005) Marin David Condic
2001-12-20 20:14   ` FGD
2001-12-20 20:34     ` Marin David Condic [this message]
2001-12-21 17:21       ` FGD
2001-12-21 18:08         ` Marin David Condic
2001-12-21 19:40           ` tmoran
2001-12-21 19:45             ` Marin David Condic
2001-12-21 20:35             ` Dan Nagle
2001-12-21 20:31           ` Eric Merritt
2001-12-22 16:56           ` Math Update for Ada 2005 Steven Deller
2001-12-23 15:13             ` Robert Dewar
2001-12-23 22:43               ` Brian Rogoff
2001-12-22 21:48           ` Math Libraries (was Re: Ada2005) FGD
2002-01-02 14:20         ` Jacob Sparre Andersen
2001-12-20 23:20   ` Robert C. Leif, Ph.D.
2001-12-21 14:49     ` Marin David Condic
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox