Ada Programming/Libraries/Ada.Numerics.Generic Elementary Functions
< Ada Programming < LibrariesComputing » Computer Science » Computer Programming » Ada Programming

The generic package Ada.Numerics.Generic_Elementary_Functions defines various mathematical functions for floating point type. Being generic it can not only be used for predefined floating point types but also for any user defined floating type.
Usage
There is an extensive usage guide in Ada Programming/Mathematical calculations. Here the relevant extract:
with Ada.Numerics.Generic_Elementary_Functions; procedure Numeric_4 is type Value_Type is digits 12 range -999_999_999_999.0e999 .. 999_999_999_999.0e999; package Value_Functions is new Ada.Numerics.Generic_Elementary_Functions ( Value_Type);
See also
Wikibook
Ada Reference Manual
Ada 95
Ada 2005
This article is issued from Wikibooks. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.