12.07.2015 Views

PGI Fortran - Servidor WWW del Cluster Ladon-Hidra

PGI Fortran - Servidor WWW del Cluster Ladon-Hidra

PGI Fortran - Servidor WWW del Cluster Ladon-Hidra

SHOW MORE
SHOW LESS
  • No tags were found...

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

After data is transferred, the file is positioned after the last record read or written, if there is noerror condition or end-of-file condition set. Unformatted data transfer cannot be carried out if thefile is connected for formatted input/output.The following example shows an unformatted input statement:READ (2, ERR=50) A, BOn output to a file connected for direct access, the output list must not specify more values thancan fit into a record. If the values specified do not fill the record the rest of the record is undefined.On input, the file must be positioned so that the record read is either:• An unformatted record or an endfile record.• The number of values required by the input list in the input statement must be less than orequal to the number of values in the record being read. The type of each value in the recordmust agree with that of the corresponding entity in the input list. However one complex valuemay correspond to two real list entities or vice versa. If the input list item is of typeCHARACTER, its length must be the same as that of the character valueIn the event of an error condition, the position of the file is indeterminate.5.5 Formatted Data TransferDuring formatted data transfer, data is edited to conform to a format specification, and the editeddata is transferred between the items specified in the input or output statement’s iolist and the file;the current record is read or written and, possibly, so are additional records. On input, the file mustbe positioned so that the record read is either a formatted record or an endfile record. Formatteddata transfer is prohibited if the file is connected for unformatted input/output.For variable length record formatted input, each newline character is interpreted as a recordseparator. On output, the I/O system writes a newline at the end of each record. If a program writesa newline itself, the single record containing the newline will appear as two records when read orbackspaced over. The maximum allowed length of a record in a variable length record formattedfile is 2000 characters.5.5.1 Implied DO List Input Output ListAn implied DO list takes the form(iolist,do-var=var1,var2,var3)156 Chapter 6

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!