Real array to 16 bit packed format.
More...
Go to the source code of this file.
|
subroutine | q9e3i6 (a, b, n, istat) |
| Convert ieee 32 bit task 754 floating point numbers to ibm370 64 bit floating point numbers.
|
|
subroutine | q9ei32 (a, b, n, istat) |
| Convert IEEE 32 bit task 754 floating point numbers to IBM370 32 bit floating point numbers.
|
|
subroutine | w3ai00 (real8, pack, label) |
| Converts IEEE floating point numbers to 16 bit packed office note 84 format.
|
|
Real array to 16 bit packed format.
- Author
- Ralph Jones
- Date
- 1985-07-31
Definition in file w3ai00.f.
◆ q9e3i6()
subroutine q9e3i6 |
( |
integer(4), dimension(n) |
a, |
|
|
integer(4), dimension(2,n) |
b, |
|
|
|
n, |
|
|
|
istat |
|
) |
| |
Convert ieee 32 bit task 754 floating point numbers to ibm370 64 bit floating point numbers.
Program history log:
- Ralph Jones 1992-08-02
- Ralph Jones 1995-11-15 Add save statement.
- Parameters
-
[in] | A | Real*4 array of IEEE 32 bit floating point numbers. |
[in] | N | Number of words to convert to IBM370 64 bit F.P. |
[out] | B | Real*8 array of IBM370 64 bit floating point numbers. |
[out] | ISTAT |
- 0 All numbers converted.
- -1 N is less than one.
- +K K infinity or nan numbers were found.
|
- Note
- See IEEE task 754 standard floating point arithmetic for more information about IEEE F.P.
- Author
- Ralph Jones
- Date
- 1992-08-02
Definition at line 366 of file w3ai00.f.
◆ q9ei32()
subroutine q9ei32 |
( |
integer(4), dimension(*) |
a, |
|
|
integer(4), dimension(*) |
b, |
|
|
|
n, |
|
|
|
istat |
|
) |
| |
Convert IEEE 32 bit task 754 floating point numbers to IBM370 32 bit floating point numbers.
Program history log:
- Ralph Jones 1990-06-04 Convert to sun fortran 1.3.
- Ralph Jones 1990-07-14 Change ishft to lshift or lrshft.
- Ralph Jones 1991-03-28 Change to silicongraphics 3.3 fortran 77.
- Ralph Jones 1992-07-20 Change to ibm aix xl fortran.
- Ralph Jones 1995-11-15 Add save statement.
- Stepen Gilbert 1998-11-18 Specified 4-byte Integer values.
- Parameters
-
[in] | A | - Real*4 array of IEEE 32 bit floating point numbers. |
[in] | N | - Number of words to convert to IBM370 32 bit F.P. |
[out] | B | - Real*4 array of IBM370 32 bit floating point numbers. |
[out] | ISTAT |
- 0: All numbers converted.
- -1: N is less than one.
- +K: K infinity or nan numbers were found.
|
- Note
- See IEEE task 754 standard floating point arithmetic for more information about IEEE F.P.
- Author
- Ralph Jones
- Date
- 1990-06-04
Definition at line 270 of file w3ai00.f.
◆ w3ai00()
subroutine w3ai00 |
( |
real, dimension(*) |
real8, |
|
|
integer(8), dimension(*) |
pack, |
|
|
integer(8), dimension(6) |
label |
|
) |
| |
Converts IEEE floating point numbers to 16 bit packed office note 84 format.
The floating point number are converted to 16 bit signed scaled integers.
Program history log:
- Ralph Jones 1989-10-20 Convert cyber 205 version of w3ai00 to cray.
- Ralph Jones 1990-03-18 Change to use cray integer*2 packer.
- Ralph Jones 1990-10-11 Special version to pack grids larger than 32743 words. Will do old and new version.
- Ralph Jones 1991-02-16 Changes so equivalence of pack and real8 arrays will work.
- Ralph Jones 1993-06-10 Changes for array size (512,512) 262144 words.
- Boi Vuong 1998-03-10 Remove the cdir$ integer=64 directive.
- Stephen Gilbert 1998-11-18 Changed to pack IEEE values for the IBM SP
- Parameters
-
[in] | REAL8 | Array of cray floating point numbers. |
[in] | LABEL | Six 8-byte integer words. Must have first 8 of 12 32 bit word office note 84 label. word 6 must have in bits 31-00 the number of real words in array real8 if j is greater than 32743. j in bits 15-0 of the 4th id word is set zero. |
[out] | PACK | Packed output array of integer words of size 6 + (j+3)/4 , j = no. points in label (from word 4 bits 15-00). Label will be copied to pack words 1-4.
- Pack will contain the following in words 5-6:
- word 5 bits 63-48 Number of bytes in whole record. will not be correct if j > 32743.
- word 5 bits 47-32 Exclusive-or checksum by 16 bit words of whole array pack excluding checksum itself.
- word 5 bits 31-00 Center value a = mean of max and min values. converted to ibm 32 floating point number.
- word 6 bits 63-48 Zero.
- word 6 bits 47-32 16 bit shift value n. the least integer such that abs(x-a)/2**n lt 1 for all x in real8. limited to +-127.
- word 6 bits 31-00 Number of words in real8 if > 32743, right adjusted if <= 32743 set zero.
|
- Note
- Pack and label may be equivalenced. n, the number of points in a grid is now in 32 bit id word 12.
- Author
- Ralph Jones
- Date
- 1985-07-31
Definition at line 39 of file w3ai00.f.