1# Data file for mpc_add. 2# 3# Copyright (C) 2008 INRIA 4# 5# This file is part of GNU MPC. 6# 7# GNU MPC is free software; you can redistribute it and/or modify it under 8# the terms of the GNU Lesser General Public License as published by the 9# Free Software Foundation; either version 3 of the License, or (at your 10#o ption) any later version. 11# 12# GNU MPC is distributed in the hope that it will be useful, but WITHOUT ANY 13# WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS 14# FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for 15# more details. 16# 17# You should have received a copy of the GNU Lesser General Public License 18# along with this program. If not, see http://www.gnu.org/licenses/ . 19# 20# The line format respects the parameter order in function prototype as 21# follow: 22# 23# INEX_RE INEX_IM PREC_ROP_RE ROP_RE PREC_ROP_IM ROP_IM PREC_OP1_RE OP1_RE PREC_OP1_IM OP1_IM PREC_OP2_RE OP2_RE PREC_OP2_IM OP2_IM RND_RE RND_IM 24# 25# where op1 = op1_re + i * op1_im, op2 = op2_re + i * op2_im, rop = rop_re + i * rop_im, 26# The data are read from the file and stored in variables op1, op2, rop using 27# rounding to nearest when needed, for instance: rop_re is ROP_RE rounded to 28# nearest to the precision of PREC_ROP_RE. 29# ROP_RE is checked against Re(op1 + op2) rounded to the precision PREC_ROP_RE 30# in the direction RND_RE 31# ROP_IM is checked against Im(op1 + op2) rounded to the precision PREC_ROP_IM 32# in the direction RND_IM 33# INEX_RE is the ternary value for the real part with the following notation: 34# "?" ternary value not checked 35# "+" if ROP_RE is greater than the exact mathematical result 36# "0" if ROP_RE is exactly the mathematical result 37# "-" if ROP_RE is less than the exact mathematical result 38# (m.m. INEX_IM) 39# rounding modes notation: 40# "N" is rounding to nearest 41# "Z" is rounding towards zero 42# "U" is rounding towards plus infinity 43# "D" is rounding towards minus infinity 44# Use prefixes "0b" for values in base two, "0x" for values in base sixteen, 45# no prefix for value in base ten. 46# In all bases, "nan" is NaN, "inf" is infinity; 47# The sign of the result is checked with "+inf", "-inf", "-0", or "+0". 48 49# special values (following ISO C99 standard) 500 0 53 -inf 53 -inf 53 -inf 53 -inf 53 -inf 53 -inf N Z 510 0 53 -inf 53 nan 53 -inf 53 +inf 53 +1 53 -inf Z U 520 0 53 +inf 53 -inf 53 +inf 53 -inf 53 +inf 53 +0 U D 530 0 53 +inf 53 +inf 53 +inf 53 +inf 53 -0 53 -1 D N 540 0 53 -inf 53 -inf 53 -inf 53 -inf 53 -0 53 -1 N U 550 0 53 nan 53 nan 53 -inf 53 +inf 53 +inf 53 nan Z D # check this is true in ISO C99 560 0 53 nan 53 -inf 53 +inf 53 -inf 53 nan 53 -1 U N 570 0 53 +inf 53 nan 53 +inf 53 +inf 53 -0 53 nan D Z 580 0 53 nan 53 nan 53 -inf 53 -inf 53 nan 53 nan N D 59 600 0 53 +inf 53 -inf 53 -1 53 -inf 53 +inf 53 -1 N D 610 0 53 nan 53 +1 53 -inf 53 +1 53 +inf 53 -0 Z N 620 0 53 +1 53 -inf 53 +1 53 -inf 53 -0 53 +1 U Z 630 0 53 +inf 53 +1 53 +inf 53 +1 53 -0 53 -0 D U 640 0 53 +inf 53 nan 53 -1 53 -inf 53 +inf 53 nan N N 650 0 53 nan 53 +2 53 -inf 53 +1 53 nan 53 +1 Z Z 660 0 53 +1 53 nan 53 +1 53 -inf 53 -0 53 nan U U # check this 670 0 53 nan 53 nan 53 +inf 53 +1 53 nan 53 nan D D 68 690 0 53 -0 53 nan 53 -0 53 -inf 53 +0 53 +inf D D 700 0 53 -inf 53 +0 53 -inf 53 +0 53 +1 53 -0 N Z 710 0 53 +0 53 -inf 53 +0 53 -inf 53 -0 53 -0 Z U 720 0 53 nan 53 nan 53 +inf 53 +0 53 -inf 53 nan U D # check 730 0 53 nan 53 -inf 53 -0 53 -inf 53 nan 53 -1 D N 740 0 53 -inf 53 nan 53 -inf 53 +0 53 +0 53 nan N U 750 0 53 nan 53 nan 53 +0 53 -inf 53 nan 53 nan Z D 76 770 0 53 +0 53 -0 53 +0 53 +1 53 -0 53 -1 Z D 780 0 53 -1 53 -0 53 -1 53 -0 53 +0 53 -0 U N 790 0 53 nan 53 +inf 53 -0 53 +1 53 nan 53 +inf D Z 800 0 53 +0 53 nan 53 +1 53 -0 53 -1 53 nan N D 810 0 53 nan 53 +1 53 +0 53 +1 53 nan 53 -0 Z N 820 0 53 nan 53 nan 53 -1 53 -0 53 nan 53 nan U Z 83 840 0 53 +0 53 +0 53 -0 53 +0 53 +0 53 -0 U Z 850 0 53 nan 53 -inf 53 +0 53 -0 53 nan 53 -inf D U 860 0 53 -1 53 nan 53 +0 53 +0 53 -1 53 nan N N 870 0 53 nan 53 -0 53 -0 53 -0 53 nan 53 -0 Z Z 880 0 53 nan 53 nan 53 -0 53 +0 53 nan 53 nan U U 89 900 0 53 nan 53 nan 53 nan 53 -inf 53 nan 53 +inf U U # check 910 0 53 +inf 53 nan 53 +inf 53 nan 53 -1 53 nan D D 920 0 53 nan 53 -inf 53 nan 53 -inf 53 nan 53 -0 N Z 930 0 53 nan 53 nan 53 -inf 53 nan 53 nan 53 nan Z U # check 94 950 0 53 nan 53 nan 53 +1 53 nan 53 nan 53 -1 Z U 960 0 53 nan 53 nan 53 nan 53 +1 53 -0 53 nan U D 970 0 53 nan 53 nan 53 -1 53 nan 53 nan 53 nan D N 98 990 0 53 nan 53 nan 53 nan 53 +0 53 +0 53 nan D N 1000 0 53 nan 53 nan 53 +0 53 nan 53 nan 53 nan N U 101 1020 0 53 nan 53 nan 53 nan 53 nan 53 nan 53 nan N U 103 104# pure real argument 105+ 0 53 0x10000000000001p-52 53 -0 53 +1 53 -0 53 0x10000000000001p-105 53 -0 N N 106- 0 53 0x10000000000000p-52 53 -0 53 +1 53 -0 53 0x10000000000001p-105 53 -0 Z Z 107+ 0 53 0x10000000000001p-52 53 -0 53 +1 53 -0 53 0x10000000000001p-105 53 -0 U U 108- 0 53 0x10000000000000p-52 53 -0 53 +1 53 -0 53 0x10000000000001p-105 53 -0 D D 109 110# pure imaginary argument 1110 + 53 -0 53 0x10000000000001p-52 53 -0 53 0x10000000000001p-105 53 -0 53 +1 N N 1120 - 53 +0 53 0x10000000000000p-52 53 +0 53 0x10000000000001p-105 53 -0 53 +1 Z Z 1130 + 53 +0 53 0x10000000000001p-52 53 +0 53 0x10000000000001p-105 53 -0 53 +1 U U 1140 - 53 -0 53 0x10000000000000p-52 53 -0 53 0x10000000000001p-105 53 -0 53 +1 D D 115 116