Manuel d'utilisation / d'entretien du produit fortran-80 du fabricant Intel
Aller à la page of 130
FORTRAN-SO PROGRAMMING MANUAL Manual Order Number: 9800481 A I Copyright © 1978 Intel Corporation Intel Corporation, 3065 Bowers Avenue, Santa Clara, California 95051 .
ii The information in this document is subject to change without notice. Intel Corporation makes no warranty of any kind with regard to this material, including, but not limited to, the implied warranties of merchantability and fitness for a particular purpose.
PREFACE This manual describes the Intel-developed FORTRAN language (FORTRAN-80) for programming the 8080 and 8085 microcomputers. FORTRAN-80 is based on the ANSI FORTRAN 77 subset. In some instances, it incorporates features from the FORTRAN 77 full language; FORTRAN-80 also has features that exceed both ver- sions of FORTRAN 77.
.
PREF'ACE GLOSSARY CHAPTER 1 INTRODUCTION TO FORTRAN 1.1 An Introductory Example ................ , 1-1 1.1.1 Comment Lines .................... 1-1 1.1.2 Type Statement ................... , 1-2 1.1.3 Input Statement ................... , 1-2 1.1.
6.2 File-Handling Statements. . . . . . . . . . . . . . . .. 6-4 6.2.1 OPEN Statement. . . . . . . . . . . . . . . . . .. 6-4 6.2.2 CLOSE Statement. ............... " 6-8 6.2.3 BACKSPACE Statement. . . . . . . . . . . .. 6-9 6.2.4 REWIND Statement .
GLOSSARY Argument(s) - A collection of values and variables on which a computation is per- formed. Functions and subroutines are usually defined with dummy arguments that are replaced with actual values when the functions or subroutines are referenced.
Glossary viii Program Unit - Another name for a main program or a subprogram. Every program unit must be terminated by an END statement. Record - A sequence of values or characters. Statement - A sequence of syntactic items: statement label, keyword, arguments, ex- pressions, etc.
CHAPTER 11 INTRODUCTION TO FORTRAN This chapter opens with a short example intended to give the newcomer to FOR- TRAN a feel for the language. The example is discussed in some d.etail. The chapter also includes a summary of FORTRAN-80 statements and their proper coding se- quence.
Introduction To FORTRAN 1-2 1.1.2 Type Statement Every variable used in a FORTRAN program has a type - integer, real, logical, character, or Hollerith. The CHARACTER type statement says that the variable PNAME represents character data and may have up to 12 characters.
FORTRAN-SO Introduction To FORTRAN Statement 20, the FORMAT statement, indicates the 'PNAME' field will be a string of characters of variable length, as in the FORMAT statement labeled 10. The name will be followed by five blanks (5X) and then the batting average will be printed.
Introduction To FORTRAN 1-4 1.2.3 Order of Statements The following order must be observed in coding FORTRAN statements lines: 1. Comment lines can appear before or between statements. They cannot appear after the END statement. 2. The PROGRAM statement can appear only as the first statement of a main program.
CHAPTER 2 FORTRAN CONCEPTS The chapter discusses the concepts and terminology used to describe the structure and elements of a FORTRAN program. 2.1 FORTRAN Program Structure 2.1.1 Program U nits and Procedures The scope of many FORTRAN operations is defined to be a program unit.
FORTRAN Concepts 2-2 2.1.2 The PROG RAM Statement The PROGRAM statement is used to name a program. This statement is optional, but when present must be the first statement of a main program. It has the format PROGRAM name where 'name' is the symbolic name of the program.
FORTRAN-80 FORTRAN Concepts 2.2 FORTRAN Statement Elements A FORTRAN statement can include the following elements: • Statement identifier (keyword), such as PROGRAM or INTEGER • Function identifiers, such as SQRT(A) or FLOA T(I) • Constants, such as 3.
:FORTRAN Concepts 2-4 2.2.2 Constants and Variables The value of a constant does not change from one execution of a program to the next. The value of a variable, on the other hand, is subject to change during pro- gram execution or between runnings of the program.
FORTRAN-80 FORTRAN Concepts Character data is a string of any characters representable in the processor. The blank character is valid and significant in a character constant. A character constant has the form of a string of characters surrounded by apostrophes.
FORTRAN Concepts 2-6 The possibleJorms of aninteger constant are: [s]d" . or [sl#d ... b where: s is an optional + or -. sign d is a digitor.one of the letters A~F b designates the number base and is one of the letters D,B,O; Q, or H lfthe numher base specjfier is absent or is the letter >'D/thecharacler string 'd .
FORTRAN-80 FORTRAN Concepts 2.2.4 Expressions and Operators An expression is a combination of numbers, symbols, and operators. It may include parentheses and may also include functions (discussed in Chapter 5). Expressions appear in assignment statements (e.
FORTRAN Concepts 2-8 Fig. 2w$ ·.type,. Length, andJnterpretatbin o~(O~1**QP2) As these figures indicate, mixed-mode arithmetic is done by converting both operands to the same type (the type of the result) before performing the operation. This conversion is unnecessary when a real number is raised to an integer power.
FORTRAN-SO f'ORTRAN Concepts Relational expressions are commonly used in the IF statement (Chapter 4). IF (NUMB .GT. 99) STOP IF (PNAME .EO. 'GEHRIG') PRINT 20, PNAME, AVG 2.
FORTRAN Concepts 2-10 The following example passes control to line 10 if the logical variable DONE is not true. Otherwise, execution stops. 10 FLAG = FLAG + 1 DONE = (FLAG .GT. 99) IF (.NOT. DONE) THEN GOTO 10 ELSE STOP ENDIF The value when two logical operands are combined by .
FORTRAN-80 FORTRAN Concepts The following statement returns whenever the two logical operands are logically equivalent. IF (FLAG1 .EQV. FLAG2) RETURN The value when two logical operands are combined by .
.FORTRAN Concepts 2-12 Parentheses can be used to override normal rules of precedence. The part of an ex- pression enclosed in parentheses is evaluated first.
FORTRAN-80 FORTRAN Concepts • Statement function names • Intrinsic function names • Dummy procedure names Variables appearing as dummy arguments in a statement function have a scope of that statement only. Common block names are generally global, but do admit exceptions.
.
CHAPTER 3 DEFINING VARIABLES, ARRAYS, AND MEMORY This chapter describes the statements used to specify the types and lengths associated with symbolic names, how to assign values to these symbols, .how to structure memory, and how to assign values to a block of memory.
Defining Variables, Arrays, And Memory 3-2 where 'name' is one of the forms and v[*/en} ary[(d)][* len] v is an integer variable, function, or dummy procedure name ary is an array name ary( d) is an array declarator lenj.i~~~~l~9:!~~i*~~f¢~;0;(<trl·.
FORTRAN-SO Defining Variables t Arrayst And Memory Examples: LOGICAL *2 FLAG LOGICAL* 1 FLAGS(10) LOGICAL *4 FLAG1, FLAG2, SWITCH(5)*1 3.1.4 CHARACTER Type Statement The CHARACTER type statement has the format: CHARACTER [* len[,]] name [,name] .
Defining Variables, Arrays, And Memory 3-4 The IMPLICIT statement has the format: IMPLICIT typ (let [,/et] ... ) [,typ (let [,let]. .. )]. .. where typ is INTEGERf*bml , REAL, LOGICALt~lejz], or CHARACTER[* len] let is a single letter or a range of letters in alphabetical order (e.
FORTRAN-80 Defining Variables, Arrays, And Memory By 'array element name' we mean an array name qualified by a subscript in paren- theses as shown in the example above. An array name not qualified by a sUbscript identifies the entire array, with one exception.
Defining Variables, Arrays, And Memory 3-6 3.2.3 Properties of Arrays The examples following the description of the DIMENSION statement specify the types of the array names and, by implication, the types of the elements in the ar- rays. They also specify (by default) the lengths of the elements.
FORTRAN-80 Defining Variables, Arrays, And Memory where 'ary' is an array name and's' is a subscript. The number of subscripts must equal the number of dimensions in the array declarator. Each subscript is an integer expression in the range 1 :5 s:5 upper-bound.
Defining Variables, Arrays, And Memory 3-8 3.3.1 Arithmetic Assignment Statement The arithmetic assignment statement closely resembles a conventional arithmetic formula.
FORTRAN-SO Defining Variables, Arrays, And Memory 3.3.2 Logical Assignment Statement The logical assignment statement assigns the value. TRUE. or .FALSE.
Defining Variables, Arrays, And Memory 3-10 The ASSIGN statement has the format: ASSIGN stlTO name where stl is a statement label (1-5 digits) name is an integer variable name The statement label must be the label of an executable statement or a FORMA T statement in the same program unit as the ASSIGN statement.
FORTRAN-80 Defining Variables, Arrays, And Memory Items in DATA lists must agree in number, type, and length. 'Nlist' and 'elist' must have the same number of items, as the lists correspond one- to-one.
Defining Variables, Arrays, And Memory 3-12 where 'nlist' is a list of variable names, array names or array element names. The lat- ter may only be subscripted by integer constants. The use of an array name un- qualified by a subscript is the same as a reference to the first element of the array.
FORTRAN-80 Defining Variables, Arrays, And Memory The items in 'nlist' following a common block name (or omitted name) are declared to be in that block (or in blank common). If a common block name is omitted, the statement refers to the blank common block.
Defining Variables, Arrays, And Memory 3-14 3.4.4 BLOCK DATA Statement The format of the BLOCK DATA statement is: BLOCK DATA [name] where 'name' is the symbolic name of the BLOCK DATA subprogram.
CHAPTER 4 PROGRAM EXECUTION CONTROLS FORTRAN includes 16 statements, or statement variations, for controlling program execution. These are statements that transfer control (GO TO, IF, and their varia- tions), regulate execution loops (DO, CONTINUE), and terminate program execu- tion (PAUSE, STOP, END).
Program Execution Controls 4-2 Examples: GO TO (1010,1020,1030) K C IF K = 2, FOR EXAMPLE, CONTROL PASSES TO STATEMENT C 1020 INTEGER*1 SWITCH SWITCH = K/J GO TO (10,500,500,10,10) SWITCH C NOTE THAT 'J' MUST BE .LE. 'K' IN THIS EXAMPLE GO TO (10, 500, 600, 500) K * L + 1 4.
FORTRAN-SO Program Execution Controls Examples: IF(A + 8)1010,1020,1030 SWITCH = A**2 - 8**2 IF (SWITCH) 100,200,300 4.1.5 Logical I F Statement We have given several examples of logical IF statements already in this manual. In effect, if the logical expression evaluated is TRUE, a specified statement is executed next.
Program Execution Controls 4-4 An ELSE block consists of all the executable statements after the ELSE statement up to, but not including, the next END IF statement that has the same nesting level as the ELSE statement. For each block IF statement, there must be a corresponding END IF statement in the same program unit.
FORTRAN-80 Program Execution Controls If 'exp' is TRUE, normal execution continues with the first statement of the ELSE IF block. If 'exp' is FALSE, control passes to the next ELSE IF, ELSE, or END IF statement having the same level as the ELSE IF statement.
Program Execution Controls 4-6 4.2 Loop Control Statements Frequently, a series of operations must be repeated several times (for example, reading a series of entries from an input device and extracting information selective- ly).
FORTRAN-80 Program Execution Controls DO loops may be nested, that is, a DO loop can contain another DO loop, etc. If a DO statement appears within the range of another DO loop, the loop specified by the second DO statement must be within the range of the outer DO loop.
Program Execution Controls 4-8 4.3.1 PAUSE Statement The format of the PAUSE statement is PAUSE [msg] where 'msg' is a string of not more than five digits, or is a character constant. At the time the PAUSE is executed and program execution ceases, 'msg' is displayed on the console terminal.
CHAPTER 5 FUNCTIONS AND SUBROUTINES Functions and subroutines reduce coding, break programs into readily-visible logical structures, conserve storage, avoid the tedium and increased probability of error in repetitive coding, and eliminate the coding of commonly-used mathematical functions.
Functions And Subroutines 5-2 I f the name of an intrinsic function appears in the dummy argument list of a FUNC- TION or SUBROUTINE subprogram, the name is considered to have no relation to the intrinsic function within the scope of the program unit and the name itself loses its intrinsic quality.
FORTRAN-80 Functions And Subroutines The statement function name and the expression 'exp' may be of different types. The type of the value returned is as shown in Figure 3-2. The dummy argument list indicates the order, number and type of arguments for the statement function.
Functions And Subroutines 5-4 A statement function may be referenced only in the program unit where it is defined. The statement function may not reference another statement function if that other function is defined later in the program unit. Furthermore, a statement function in a FUNCTION subprogram must not reference the name of the subprogram.
FORTRAN-SO Functions And Subroutines An actual argument may also be a dummy argument as long as the dummy is part of a dummy argument list within the subprogram containing the external function reference. 5.2.1.2 FUNCTION Subprogram Limitations A FUNCTION statement may be used only as the first statement of a FUNCTION subprogram.
Functions And Subroutines 5-6 The subroutine is called by the CALL statement. PROGRAM CALL .. SUBROUTINE .~RETURN CA.~END END Subroutines, being external procedures, can be defined outside the program.
FORTRAN-SO Functions And Subroutines When a RETURN is executed in a FUNCTION subprogram, the value of the func- tion must be available to the referencing program unit. Whenever RETURN is executed, the association between the dummy arguments of an external procedure and the current actual arguments is terminated (but see sec- tion 5.
Functions And Subroutines 5-8 5.2.7 CALL Statement The CALL statement is used to reference a subroutine. A subroutine can be refer- enced within any other external procedure or in the main program. A subprogram must not reference itself either directly or indirectly (but see the description of the REENTRANT compiler control in section F.
FORTRAN-80 Functions And Subroutines 5.3.1 Common Blocks Common blocks reduce storage requirements by allowing two or more subprograms to share the same memory.
Functions And Subroutines 5-10 NOTE The subscript value remains constant as long as the arguments are associated, even if the subscript contains variables redefined during the association. Argument association can be carried through more than one level of procedure reference.
FORTRAN-SO Functions And Subroutines NOTE In a given program unit, det~rmining whether a dummy procedure is associated with a function or a subroutine may not be possible.
.
CHAPTER 61 INPUT/OUTPUT The FORTRAN input/output (I/O) statements transfer data between a processor and external units or within the processor itself. These statements can specify the ex- ternal units to be used, the variables whose values are being entered or output, and the format of I/O data.
Input/Output 6-2 6.1.2.1 File Existence At the time an executable program is running, a certain set of files is available. These files are said to exist, and the particular files that exist are determined by the operating system or environment in which the program is running.
FORTRAN-SO 6.1.2.5 File Access An external file can be accessed sequentially or directly. An internal file can only be accessed sequentially. Some external files may be allowed more than one access method, depending on the operating environment. The access method is determined when the file is connected to a unit.
Input/Output 6-4 6.2 File-Handling Statements 6.2.1 OPEN Statement The OPEN statement can be used to connect an existing file to a unit, create a preconnected file, create a file and connect it to a unit, or change certain specifiers in the file/unit connection.
FORTRAN-80 Executing an OPEN statement containing this specifier causes 'stname' to become defined with a zero value if no error condition exists, or with a processor-dependent positive integer value if an error condition does exist. Example: OPEN (4, IOSTAT = ERRFLG) 6.
Input/Output 6-6 If 'OLD' or 'NEW' is specified, the FILE specifier must be present also. An 'OLD' file must exist already; a 'NEW' file cannot exist already. The 'SCRATCH' option must not be specified with a named file.
FORTRAN-80 If the file is being connected for formatted 110, 'reclen' is the number of characters. If the file is being connected for unformatted 110, the length is measured in bytes. If the file already exists, the length specified must be that used when the file was created.
Input/Output 6-8 6.2.1.11 Opening A Connected Unit The OPEN statement can be specified for a unit already connected to an existing file. That existing file is assumed to be the value of 'fname' if the FILE specifier is not included in the OPEN 'open-list.
FORTRAN-80 6.2.2.2 File Disposition Specifier The format of the file disposition specifier is STATUS = stat where 'stat' is a character expression evaluating to 'KEEP' or 'DELETE'.
Input/Output 6-10 where 'unit' is an external unit specifier and 'arg-list' is a list of arguments as described for the BACKSPACE statement (section 6.2.3). If the specified file is already positioned at its initial point, or if the file is connected but does not exist, the REWIND statement has no effect.
FORTRAN-SO The list of control information specifiers is: [UNIT =] unit [FMT =] f REC = recno IOSTAT = stname ERR = stl END = stl 6.3.1.1 Control Information List U nit specifier Format specifier Record number specifier I/O status specifier Error specifier End-of-file specifier The control information list must contain a unit specifier.
Input/Output 6-12 I f the asterisk option is selected, 'ctl-list' must not include a record number specifier. If the unit specifier is an internal file, the format specifier must be present, but can- not be an asterisk. Examples: READ (2,25) PNAME, AS, HITS 25 FORMAT .
FORTRAN-SO 6.3.1.2 Input List The list 'in-list' in the READ statement identifies the items whose values are to be read. An item in an input list must be a variable name, array name, or array element name. If an array name is listed, the entire array is read in normal array element ordering sequence.
Input/Output 6-14 6.3.3 PRINT Statement The PRINT statement outputs formatted data to the default write unit. It has the format PRI NT f [,out-list] where f is a format identifier out-list is a list of the data to be written Note that the keyword 'PRINT' does not necessarily imply the default unit is a line printer or other print device.
FORTRAN-80 6.4.2 Formatted Data Transfer During formatted data transfer, data is transferred with editing between the file and the 110 list. The editing is directed by some kind of format specification.
Input/Output 6-16 6.4.3 FORMAT Statement The form of the FORMAT statement is stl FORMAT ([flist]) where stl is a 1-5 digit statement label JUst is a format specification list whose items are separated by commas Each item in 'flist' must be a repeatable edit descriptor, a nonrepeatable edit descriptor, or a parenthesized 'flist.
FORTRAN-80 Certain general remarks apply to all three of these numeric editing descriptors. • On input, leading blanks are not significant. Other blanks are treated according to the setting of the non repeatable descriptors BN and BZ and the value of the BLANK sp~cifier in the OPEN statement (section 6.
Input/Output 6-18 'E' Descriptor Editing An I/O list item matched with an 'Ew.d' or 'Ew.dEe' descriptor must be a real variable. The exponent 'e' has no effect on input data. On output, the format of the output field for a scale factor (section 6.
FORTRAN-80 A /phanumeric Editing An 110 item matched with an 'A' or 'Aw' descriptor must have type character or be defined with Hollerith data. If the field width 'w' is specified, the field consists of 'w' characters.
Input/Output 6-20 The width of the field is the length of the character string. Example: WRITE (7,100) ITSTNO 100 FORMAT ('THIS IS THE TEST NUMBER', 2X, 12) 'H' Descriptor Editing The Hollerith field descriptor is an alternate way to perform the same operation as apostrophe editing.
FORTRAN-80 Scale Factor (P) Editing A scale factor is established by the' kP' edit descriptor, where' k' represents the scale factor. It is used with the 'F' and 'E' descriptors to edit real numbers. No comma is needed between the 'P' descriptor and an immediately following 'F' or 'E.
Input/Output 6-22 scanner encounters a dollarsign at the end of a format specification list, format con;. trol terminates without positioning the file to the beginning of the next record. The donar sign .edit descriptor has no effect on direct~accessfil¢s.
FORTRAN-80 6.4.4.2 List-Directed Output The form of the values produced by list-directed output agrees in type with their cor- responding output list items. The processor separates records as necessary, so long as the end of a record does not fall within a constant (except a character constant) and blanks are not embedded within constants.
.
CHAPTER 7 PROGRAMMING GUIDELINES This chapter is by no means intended as an exhaustive discussion of programming techniques. It is intended simply as a guideline, primarily for the novice program- mer.
Programming Guidelines 7-2 As the development of a program becomes more detailed, the documentation should become correspondingly detailed. The ultimate documentation is, of course, the final program .
FORTRAN-SO Programming Guidelines The next pass is a more formal description of level two, introducing FORTRAN statements for English sentences. Level Three C INITIALIZE VARIABLES NEEDED FOR TOTALS DATA TOTEMP, TOTHRS, TOTPAY / 3*0.
Programming Guidelines 7-4 This is just a 'starter' list. Certainly, any experienced programmer could add to this checklist. Rereading such a list frequently, like rereading programming manuals, is a good way to refresh or reconfirm programming knowledge.
FORTRAN-SO Programming Guidelines When calculating a value for use in a DO loop, be sure the value is computed before the loop is entered. Otherwise, the program could compute the value again for each iteration of the loop.
Programming Guidelines 7-6 McCracken, Daniel A., A Simplified Guide to FORTRAN Programming, John Wiley & Sons, New York, 1974. Mills, Harlan B., Mathematical Foundations for Structured Programming, Technical Report, FSC 72-6012, IBM Federal Systems Division, Gaithersburg, Md.
APPENDIX A FORTRAN-80 STATEMENT SUMMARY A.1 Statement Sequence The following order of statements and lines must be observed when coding a FORTRAN program. 1. Comment lines can appear before or between statements, but cannot appear after an END statement.
FORTRAN-80 Statement Summary A-2 BACKSP ACE Statement Category: Executable Text Reference: Section 6.2.3 Formats BACKSPACE unit BACKSPACE (arg-list) Notes: 'unit' is unit specifier 'arg-list' is following argument list: [UNIT =] unit IOSTAT = stname ERR = stl Function Position file connected before preceding record.
FORTRAN-SO FORTRAN-80 Statement Summary CLOSE Statement Category: Executable Text Reference:' Section 6.2.2 Format Function CLOSE (close-list) Close file (disconnect unit) described by 'close-list.
f'ORTRAN-80 Statement Summary FORTRAN-SO DATA Statement Category: Nonexecutable Text Reference: Section 3.3.5 Format Function DATA nlist/ clist/[[,) nlist/ elist/) ... Assign values in 'elist' to items in 'nlist.' DIMENSION Statement Category: Nonexecutable, specification Text Reference: Section 3.
FORTRAN-80 FORTRAN-80 Statement Summary ELSE IF Statement Category: Executable, Block IF Text Reference: 'Section 4.1.8 Format Function ELSE IF (exp) THEN Continue execution if expression 'exp' is TRUE END Statement Category: Executable Text Reference: 4.
FORTRAN-80 Statement Summary FORTRAN-80 EQUIVALENCE Statement Category: Nonexecutable, specification Text Reference: Section 3.4.1 Format Function EQUIV ALENCE (nlist) [,(nlist)] ... Allow entities in 'nlist' to share the same storage area. EXTERNAL Statement Category: Nonexecutable, specification Text Reference: Section 5.
FORTRAN-80 FORTRAN-80 Statement Summary FUNCTION Statement Category: Nonexecutable Text Reference: Section 5.2.1 Format Function [type] FUNCTION func ([d[,d] ... J) Name the FUNCTION subprogram 'func,' define its type and dummy parameter(s) 'd.
FORTRAN-80 Statement Summary FORTRAN-SO IMPLICIT Statement Category: Nonexecutable, specification Text Reference: Section 3.1.5 Format Function IMPLICIT type (1[, 1] ... )[,type(1[,I] ... )] ... Define implicit typing for variable names whose first letter is '1' or in range '1,1.
FORTRAN-80 F'ORTRAN-80 Statement Summary OPEN Statement Category: Executable Text Reference: Section 6.2.1 Format Function OPEN (open-list) Open the specified file (connect file to unit).
f'ORTRAN-80 Statement Summary A-tO PROGRAM Statement Category: Nonexecutable Text Reference: Section 2.1.2 Format Function PROGRAM name Name main program 'name;' must be first statement if used. READ Statement Category: Executable Text Reference: Section 6.
FORTRAN-80 FORTRAN-SO Statement Summary REWIND Statement Category: Executable Text Reference: Section 6.2.4 Formats Function REWIND unit Reposition file connected to 'unit' REWIND (arg-list) at its initial point.
FORTRAN-80 Statement Summary A-12 SUBROUTINE Statement Category: Executable Text Reference: Section 5.2.2, 5.2.3 .~ormat Function SUBROUTINE sub [([d[,d] ... ])] Define SUBROUTINE subprogram 'sub' with dummy argument(s) 'd.' WRITE Statement Category: Executable Text Reference: Section 6.
APPENDIX B I INTRINSIC FUNCTIONS The following table lists the intrinsic (or predefined) functions available with FORTRAN-SO. An intrinsic function is executed in an expression by referencing its name followed by some argument in parentheses.
Intrinsic Functions FORTRAN-80 TYPE OF }<'ORM CATEGORY FUNCTION ARGUMENTS FUNCTION SIGN (aI, a2) Sign transfer Transfer sign of a2 to al Real Real (note 5) 101M (ai, a2) Positive difference Re.
FORTRAN-SO Intrinsic Functions B.2 Notes On Intrinsic Functions I. For an integer argument, 'int(a) = a.' For a real argument, two possibilities exist.
.
APPENDIX C HOLLERITH DATA TYPE The Hollerith data type is a carryover from FORTRAN 66. Generally speaking, the character data type provides a superior processing capability, and Hollerith has been retained in FORTRAN-80 primarily for compatibility with the earlier standard.
Hollerith Data Type C-2 C.3 Hollerith Format Specification A format specification may be an array name of type integer, real, or logical. In this case, the leftmost characters of the specified entity must contain Hollerith data con- stituting a legal format specification.
APPENDIX D EXTENSIONS TO ANSI FORTRAN This appendix lists differences between FORTRAN-80 and ANSI FORTRAN 77. Some of these are extensions to the FORTRAN 77 subset which are included in the FORTRAN 77 full language. Other extensions go beyond both versions of the ANSI standard.
Extensions To ANSI Fortran D-2 0.3 More Specific Semantics Than 1977 FORTRAN In the following areas, the definition of FORTRAN-80 is more explicit than the AN- SI standard. 1. The character set and its collating sequence include the ASCII character set.
FORTRAN-80 Extensions To ANSI Fortran Miscellaneous extensions: Seven-dimensional arrays Unsubscripted array names in DATA and EQUIVALENCE statements Optional commas in COMMON, DO, assigned GOTO, and .
.
APPENDIX E I ASCII CODES The following table lists the ASCII characters representable on Intel processors and their collating sequence. GRA CO PHICOR NTROL JL NL SO ST ET EO EN AC 8E 8S HT LF VT FF CR.
.
APPENDIX F 8080/8085 PROCESSOR DEPENDENCIES Throughout this manual, aspects of the FORTRAN language have been said to be 'processor dependent' or 'compiler dependent.' This appendix summarizes the limitations and extensions to the FORTRAN language assumed by the 8080/8085 processors and compiler.
SOSO/SOS5 Processor Dependencies F-2 F .2.1 Lowercase Letters Except within Hollerith and character constants, a lowercase letter is considered to be identical to its corresponding uppercase letter. F.2.2 Port Input/Output The compiler provides two intrinsic subroutines for handling input/ output through SOSO/SOS5 110 ports.
FORTRAN-SO SOSO/SOS5 Processor Dependencies If the FREEFORM compiler control is set, column 1 is interpreted as follows: Column 1 Cor * 0-9 Space or TAB & $ Meaning Comment line (same as standard).
SOSO/SOS5 Processor Dependencies F-4 The included file may itself contain INCLUDE controls, up to a total of six files. An included file cannot contain an END statement, however. An INCLUDE control must be the rightmost control when specified in a list of controls.
INDEX I The page numbers shown in italics in this index denote primary references. ABS Intrinsic Function, B-1 ACCESS I/O Specifier, 6-6 Access Method Specifier, 6-6 ACOS Intrinsic Function, B-2 Actua.
Index Index-2 FREEFORM Compiler Control, F-2 Functions, 2-1, 5-1 ff FUNCTION Statement, 5-4, A-7 FUNCTION Subprograms, 5-4 GO TO Statements, Assigned, 4-2, A-7 Computed, 4-1, A-7 Unconditional, 4-1, A.
FORTRAN-SO Subroutines, 2-1, 5-5 SUBROUTINE Statement, 5-6, A-12 SUBROUTINE Subprograms, 5-5 Symbols, 2-4, 2-12 TANH Intrinsic Function, B-2 TAN Intrinsic Function, B-2 Type Statements, 1-2, 3-1 Unfor.
.
NOTES.
NOTES.
inter SOFTWARE SUBMITTED BY: Name Company Address Phone Date CHECK ONE ITEM IN EACH CATEGORY Product Product Type o Software o Monitor o Simulator o Manual o Assembler o Editor o Compiler o Utility 0 ___ _ Exact Product/Manual Name PROBLEM REPORT FOR INTERNAL USE ONLY No.
WE'D LIKE YOUR COMMENTS ... This document is one of a lieries describing Intel products. Your comments on the back of this form will help us produce better manuals. Each reply will be carefully reviewed by the responsible person. All comments and suggestions become the property of Intel Corporation.
FORTRAN·80 PROGRAMMING MANUAL 9800481 A REQUEST FOR READER'S COMMENTS The Microcomputer Division Technical Publications Department attempts to provide documents that meet the needs of all Intel product users. This form lets you participate directly in the documentation process.
:'0 LIKE YOUR COMMENTS ... is document is one of a series describing Intel software products. Your comments on the back of this m will help us produce better software and manuals. Each reply will be carefully reviewed by the respon- Ie person. All comments and suggestions become the property of Intel Corporation.
.
inter INTEL CORPORATION, 3065 Bowers Avenue, Santa Clara, California 95051 (408) 987-8080 Printed in U.S.A..
Un point important après l'achat de l'appareil (ou même avant l'achat) est de lire le manuel d'utilisation. Nous devons le faire pour quelques raisons simples:
Si vous n'avez pas encore acheté Intel fortran-80 c'est un bon moment pour vous familiariser avec les données de base sur le produit. Consulter d'abord les pages initiales du manuel d'utilisation, que vous trouverez ci-dessus. Vous devriez y trouver les données techniques les plus importants du Intel fortran-80 - de cette manière, vous pouvez vérifier si l'équipement répond à vos besoins. Explorant les pages suivantes du manuel d'utilisation Intel fortran-80, vous apprendrez toutes les caractéristiques du produit et des informations sur son fonctionnement. Les informations sur le Intel fortran-80 va certainement vous aider à prendre une décision concernant l'achat.
Dans une situation où vous avez déjà le Intel fortran-80, mais vous avez pas encore lu le manuel d'utilisation, vous devez le faire pour les raisons décrites ci-dessus,. Vous saurez alors si vous avez correctement utilisé les fonctions disponibles, et si vous avez commis des erreurs qui peuvent réduire la durée de vie du Intel fortran-80.
Cependant, l'un des rôles les plus importants pour l'utilisateur joués par les manuels d'utilisateur est d'aider à résoudre les problèmes concernant le Intel fortran-80. Presque toujours, vous y trouverez Troubleshooting, soit les pannes et les défaillances les plus fréquentes de l'apparei Intel fortran-80 ainsi que les instructions sur la façon de les résoudre. Même si vous ne parvenez pas à résoudre le problème, le manuel d‘utilisation va vous montrer le chemin d'une nouvelle procédure – le contact avec le centre de service à la clientèle ou le service le plus proche.