| 1 | /* |
| 2 | * IBM Accurate Mathematical Library |
| 3 | * Written by International Business Machines Corp. |
| 4 | * Copyright (C) 2001-2021 Free Software Foundation, Inc. |
| 5 | * |
| 6 | * This program is free software; you can redistribute it and/or modify |
| 7 | * it under the terms of the GNU Lesser General Public License as published by |
| 8 | * the Free Software Foundation; either version 2.1 of the License, or |
| 9 | * (at your option) any later version. |
| 10 | * |
| 11 | * This program is distributed in the hope that it will be useful, |
| 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 14 | * GNU Lesser General Public License for more details. |
| 15 | * |
| 16 | * You should have received a copy of the GNU Lesser General Public License |
| 17 | * along with this program; if not, see <https://www.gnu.org/licenses/>. |
| 18 | */ |
| 19 | |
| 20 | /******************************************************************/ |
| 21 | /* */ |
| 22 | /* MODULE_NAME:utan.h */ |
| 23 | /* */ |
| 24 | /* common data and variables prototype and definition */ |
| 25 | /******************************************************************/ |
| 26 | |
| 27 | #ifndef UTAN_H |
| 28 | #define UTAN_H |
| 29 | |
| 30 | #ifdef BIG_ENDI |
| 31 | static const mynumber |
| 32 | /* polynomial I */ |
| 33 | /**/ d3 = {{0x3FD55555, 0x55555555} }, /* 0.333... */ |
| 34 | /**/ d5 = {{0x3FC11111, 0x111107C6} }, /* 0.133... */ |
| 35 | /**/ d7 = {{0x3FABA1BA, 0x1CDB8745} }, /* . */ |
| 36 | /**/ d9 = {{0x3F9664ED, 0x49CFC666} }, /* . */ |
| 37 | /**/ d11 = {{0x3F82385A, 0x3CF2E4EA} }, /* . */ |
| 38 | /* polynomial II */ |
| 39 | /* polynomial III */ |
| 40 | /**/ e0 = {{0x3FD55555, 0x55554DBD} }, /* . */ |
| 41 | /**/ e1 = {{0x3FC11112, 0xE0A6B45F} }, /* . */ |
| 42 | |
| 43 | /* constants */ |
| 44 | /**/ mfftnhf = {{0xc02f0000, 0x00000000} }, /*-15.5 */ |
| 45 | |
| 46 | /**/ g1 = {{0x3e4b096c, 0x00000000} }, /* 1.259e-8 */ |
| 47 | /**/ g2 = {{0x3faf212d, 0x00000000} }, /* 0.0608 */ |
| 48 | /**/ g3 = {{0x3fe92f1a, 0x00000000} }, /* 0.787 */ |
| 49 | /**/ g4 = {{0x40390000, 0x00000000} }, /* 25.0 */ |
| 50 | /**/ g5 = {{0x4197d784, 0x00000000} }, /* 1e8 */ |
| 51 | /**/ gy2 = {{0x3faf212d, 0x00000000} }, /* 0.0608 */ |
| 52 | |
| 53 | /**/ mp1 = {{0x3FF921FB, 0x58000000} }, |
| 54 | /**/ mp2 = {{0xBE4DDE97, 0x3C000000} }, |
| 55 | /**/ mp3 = {{0xBC8CB3B3, 0x99D747F2} }, |
| 56 | /**/ pp3 = {{0xBC8CB3B3, 0x98000000} }, |
| 57 | /**/ pp4 = {{0xbacd747f, 0x23e32ed7} }, |
| 58 | /**/ hpinv = {{0x3FE45F30, 0x6DC9C883} }, |
| 59 | /**/ toint = {{0x43380000, 0x00000000} }; |
| 60 | |
| 61 | #else |
| 62 | #ifdef LITTLE_ENDI |
| 63 | |
| 64 | static const mynumber |
| 65 | /* polynomial I */ |
| 66 | /**/ d3 = {{0x55555555, 0x3FD55555} }, /* 0.333... */ |
| 67 | /**/ d5 = {{0x111107C6, 0x3FC11111} }, /* 0.133... */ |
| 68 | /**/ d7 = {{0x1CDB8745, 0x3FABA1BA} }, /* . */ |
| 69 | /**/ d9 = {{0x49CFC666, 0x3F9664ED} }, /* . */ |
| 70 | /**/ d11 = {{0x3CF2E4EA, 0x3F82385A} }, /* . */ |
| 71 | /* polynomial II */ |
| 72 | /* polynomial III */ |
| 73 | /**/ e0 = {{0x55554DBD, 0x3FD55555} }, /* . */ |
| 74 | /**/ e1 = {{0xE0A6B45F, 0x3FC11112} }, /* . */ |
| 75 | |
| 76 | /* constants */ |
| 77 | /**/ mfftnhf = {{0x00000000, 0xc02f0000} }, /*-15.5 */ |
| 78 | |
| 79 | /**/ g1 = {{0x00000000, 0x3e4b096c} }, /* 1.259e-8 */ |
| 80 | /**/ g2 = {{0x00000000, 0x3faf212d} }, /* 0.0608 */ |
| 81 | /**/ g3 = {{0x00000000, 0x3fe92f1a} }, /* 0.787 */ |
| 82 | /**/ g4 = {{0x00000000, 0x40390000} }, /* 25.0 */ |
| 83 | /**/ g5 = {{0x00000000, 0x4197d784} }, /* 1e8 */ |
| 84 | /**/ gy2 = {{0x00000000, 0x3faf212d} }, /* 0.0608 */ |
| 85 | |
| 86 | /**/ mp1 = {{0x58000000, 0x3FF921FB} }, |
| 87 | /**/ mp2 = {{0x3C000000, 0xBE4DDE97} }, |
| 88 | /**/ mp3 = {{0x99D747F2, 0xBC8CB3B3} }, |
| 89 | /**/ pp3 = {{0x98000000, 0xBC8CB3B3} }, |
| 90 | /**/ pp4 = {{0x23e32ed7, 0xbacd747f} }, |
| 91 | /**/ hpinv = {{0x6DC9C883, 0x3FE45F30} }, |
| 92 | /**/ toint = {{0x00000000, 0x43380000} }; |
| 93 | |
| 94 | #endif |
| 95 | #endif |
| 96 | |
| 97 | #endif |
| 98 | |