%% Copyright (c) 1995,1996 by the University of Pennsylvania %% %% For information about the distributaion, copying, and modification %% %% of this software, please read the file COPYING located in the root %% %% directory of this distribnutaion. If you did not receive the file %% %% COPYING write to Philip Wickline at the address below. %% %% 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 file %% %% COPYING for more details. %% %% For information about the structure of the Terzo lambdaProlog %% %% implementation, see the file src/README in this distribution. Please %% %% address any questions about this code or the Terzo lambdaProlog %% %% implementation to Philip Wickline at . %% %% Author: %% %% Philip Wickline %% module Real. import Exception. % Exceptions which can be handled by handle type divide_by_zero, overflow exn. % binary operators on reals. type r+, r-, r*, r/ real -> real -> real. infixl r+, r- 6. infixl r*, r/ 7. % unary operators on reals. type r~, rabs, sqrt, sin, cos, arctan, ln real -> real. % makes an ascii representation of its real number argument type real_to_string real -> string. % int_to_real coerces an integer to a real type int_to_real int -> real. % floor and ceiling round reals to integers in obvious ways, % truncate rounds towards zero type floor, ceiling, truncate real -> int. % binary predicates on reals type r<, r>, r>=, r=< real -> real -> o. infix r<, r>, r>=, r=< 4.