; * MathLib: Pilot shared library of IEEE-754 double math functions
; *
; * Library function prototypes for the calling application.  This is
; * the file that the calling application should include in order to
; * get access to the routines in the library; it serves the same
; * function as the file "math.h" normally used on systems with
; * standard math libraries.  Each function in the library has two
; * prototypes listed; the first is for the programmer-friendly
; * wrapper function in MathLib.c, the second is for the raw SYS_TRAP()
; * invocation that actually calls the library routine.
; *
; * Copyright (C) 1997 Rick Huebner
; *
; * This program is free software; you can redistribute it and/or modify
; * it under the terms of the GNU General Public License as published by
; * the Free Software Foundation; either version 2 of the License, or
; * (at your option) any later version.
; *
; * This program is distributed in the hope that it will be useful,
; * but WITHOUT ANY WARRANTY; without even the implied warranty of
; * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
; * GNU General Public License for more details.
; *
; * You should have received a copy of the GNU General Public License
; * along with this program; see file COPYING.  If not, write to the
; * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
; * Boston, MA 02111-1307, USA
; *
; * Version 1.01, 23 August 1997, Rick Huebner
; *
LibType equ  'libr'
MathLibCreator equ 'MthL'
MathLibVersion equ 1
mlErrNone       equ 0
mlErrOldVersion equ 1 ; library is older than version passed to open()
mlErrNotOpen    equ 2 ; close() without having called open() first
mlErrNoMemory   equ 3 ; can't allocate global data block

sysTrapMathLibOpen equ sysLibTrapOpen
sysTrapMathLibClose equ sysLibTrapClose
sysTrapMathLibSleep equ sysLibTrapSleep
sysTrapMathLibWake equ sysLibTrapWake



sysTrapMathLibACos equ sysLibTrapCustom ;MathLibACos(UInt refnum, double x, double *result)
sysTrapMathLibASin equ sysLibTrapCustom+1 ;MathLibASin(UInt refnum, double x, double *result)
sysTrapMathLibATan equ sysLibTrapCustom+2 ;MathLibATan(UInt refnum, double x, double *result)
sysTrapsysTrapMathLibATan2 equ sysLibTrapCustom+3 ;MathLibATan2(UInt refnum, double y, double x, double *result)
sysTrapMathLibCos equ sysLibTrapCustom+4 ;MathLibCos(UInt refnum, double x, double *result)
sysTrapMathLibSin equ sysLibTrapCustom+5 ;MathLibSin(UInt refnum, double x, double *result)
sysTrapMathLibTan equ sysLibTrapCustom+6 ;MathLibTan(UInt refnum, double x, double *result)
sysTrapMathLibSinCos equ sysLibTrapCustom+7 ;MathLibSinCos(UInt refnum, double x, double *sinx, double *cosx)
sysTrapMathLibCosH equ sysLibTrapCustom+8 ;MathLibCosH(UInt refnum, double x, double *result)
sysTrapMathLibSinH equ sysLibTrapCustom+9 ;MathLibSinH(UInt refnum, double x, double *result)
sysTrapMathLibTanH equ sysLibTrapCustom+10 ;MathLibTanH(UInt refnum, double x, double *result)
sysTrapMathLibACosH equ sysLibTrapCustom+11 ;MathLibACosH(UInt refnum, double x, double *result)
sysTrapMathLibASinH equ sysLibTrapCustom+12 ;MathLibASinH(UInt refnum, double x, double *result)
sysTrapMathLibATanH equ sysLibTrapCustom+13 ;MathLibATanH(UInt refnum, double x, double *result)
sysTrapMathLibExp equ sysLibTrapCustom+14 ;MathLibExp(UInt refnum, double x, double *result)
sysTrapMathLibFrExp equ sysLibTrapCustom+15 ;MathLibFrExp(UInt refnum, double x, double *fraction, Int *exponent)
sysTrapMathLibLdExp equ sysLibTrapCustom+16 ;MathLibLdExp(UInt refnum, double x, Int exponent, double *result)
sysTrapMathLibLog equ sysLibTrapCustom+17 ;MathLibLog(UInt refnum, double x, double *result)
sysTrapMathLibLog10 equ sysLibTrapCustom+18 ;MathLibLog10(UInt refnum, double x, double *result)
sysTrapMathLibModF equ sysLibTrapCustom+19 ;MathLibModF(UInt refnum, double x, double *intpart, double *fracpart)
sysTrapMathLibExpM1 equ sysLibTrapCustom+20 ;MathLibExpM1(UInt refnum, double x, double *result)
sysTrapMathLibLog1P equ sysLibTrapCustom+21 ;MathLibLog1P(UInt refnum, double x, double *result)
sysTrapMathLibLogB equ sysLibTrapCustom+22 ;MathLibLogB(UInt refnum, double x, double *result)
sysTrapMathLibLog2 equ sysLibTrapCustom+23 ;MathLibLog2(UInt refnum, double x, double *result)
sysTrapMathLibPow equ sysLibTrapCustom+24 ;MathLibPow(UInt refnum, double x, double y, double *result)
sysTrapMathLibSqrt equ sysLibTrapCustom+25 ;MathLibSqrt(UInt refnum, double x, double *result)
sysTrapMathLibHypot equ sysLibTrapCustom+26 ;MathLibHypot(UInt refnum, double x, double y, double *result)
sysTrapMathLibCbrt equ sysLibTrapCustom+27 ;MathLibCbrt(UInt refnum, double x, double *result)
sysTrapMathLibCeil equ sysLibTrapCustom+28 ;MathLibCeil(UInt refnum, double x, double *result)
sysTrapMathLibFAbs equ sysLibTrapCustom+29 ;MathLibFAbs(UInt refnum, double x, double *result)
sysTrapMathLibFloor equ sysLibTrapCustom+30 ;MathLibFloor(UInt refnum, double x, double *result)
sysTrapMathLibFMod equ sysLibTrapCustom+31 ;MathLibFMod(UInt refnum, double x, double y, double *result)
sysTrapMathLibIsInf equ sysLibTrapCustom+32 ;MathLibIsInf(UInt refnum, double x, Int *result)
sysTrapMathLibFinite equ sysLibTrapCustom+33 ;MathLibFinite(UInt refnum, double x, Int *result)
sysTrapMathLibScalBN equ sysLibTrapCustom+34 ;MathLibScalBN(UInt refnum, double x, Int exponent, double *result)
sysTrapMathLibDRem equ sysLibTrapCustom+35 ;MathLibDRem(UInt refnum, double x, double y, double *result)
sysTrapMathLibSignificand equ sysLibTrapCustom+36 ;MathLibSignificand(UInt refnum, double x, double *result)
sysTrapMathLibCopySign equ sysLibTrapCustom+37 ;MathLibCopySign(UInt refnum, double x, double y, double *result)
sysTrapMathLibIsNaN equ sysLibTrapCustom+38 ;MathLibIsNaN(UInt refnum, double x, Int *result)
sysTrapMathLibILogB equ sysLibTrapCustom+39 ;MathLibILogB(UInt refnum, double x, Int *result)
sysTrapMathLibRInt equ sysLibTrapCustom+40 ;MathLibRInt(UInt refnum, double x, double *result)
sysTrapMathLibNextAfter equ sysLibTrapCustom+41 ;MathLibNextAfter(UInt refnum, double x, double y, double *result)
sysTrapMathLibRemainder equ sysLibTrapCustom+42 ;MathLibRemainder(UInt refnum, double x, double y, double *result)
sysTrapMathLibScalB equ sysLibTrapCustom+43 ;MathLibScalB(UInt refnum, double x, double exponent, double *result)
sysTrapMathLibRound equ sysLibTrapCustom+44 ;MathLibRound(UInt refnum, double x, double *result)
sysTrapMathLibTrunc equ sysLibTrapCustom+45 ;MathLibTrunc(UInt refnum, double x, double *result)
sysTrapMathLibSignBit equ sysLibTrapCustom+46 ;MathLibSignBit(UInt refnum, double x, ULong *result)
 
