NAG Library Routine Document

x04baf (line_write)

1
Purpose

x04baf writes a single formatted record to an external file.

2
Specification

Fortran Interface
Subroutine x04baf ( nout, rec)
Integer, Intent (In):: nout
Character (*), Intent (In):: rec
C Header Interface
#include <nagmk26.h>
void  x04baf_ (const Integer *nout, const char *rec, const Charlen length_rec)

3
Description

x04baf is used by NAG Library routines to write formatted records to an external file. All formatted output to an external file from NAG Library routines is performed by calls to x04baf.

4
References

None.

5
Arguments

1:     nout – IntegerInput
On entry: the Fortran unit number which identifies the file to be written to. If nout<0 (not a valid Fortran unit number), then no output occurs. Within the NAG Library nout is always determined by a call to x04aaf or x04abf.
2:     rec – Character(*)Input
On entry: a character-string. This is written to the external file as a single record. Trailing blanks are not output, except that if rec is entirely blank, a single blank character is output. If the record is printed, the first character is treated as a carriage-control character.

6
Error Indicators and Warnings

None.

7
Accuracy

Not applicable.

8
Parallelism and Performance

x04baf is not threaded in any implementation.

9
Further Comments

None.

10
Example

This example program simply illustrates how a formatted record is output from the NAG Library, by first writing it to the character-string rec, used as an internal file, and then passing the character-string to x04baf.

10.1
Program Text

Program Text (x04bafe.f90)

10.2
Program Data

None.

10.3
Program Results

Program Results (x04bafe.r)