• Embed Doc
  • Readcast
  • Collections
  • CommentGo Back
Download
 
1
 F
ortran
90
O
verview
 J.E. Akin, Copyright 1998
This overview of Fortran 90 (F90) features is presented as a series of tables that illustrate the syntaxand abilities of F90. Frequently comparisons are made to similar features in the C++ and F77 languagesand to the Matlab environment.These tables show that F90 has significant improvements over F77 and matches or exceeds newersoftware capabilities found in C++ and Matlab for dynamic memory management, user defined datastructures, matrix operations, operator definition and overloading, intrinsics for vector and parallel pro-cessors and the basic requirements for object-oriented programming.They are intended to serve as a condensed quick reference guide for programming in F90 and forunderstanding programs developed by others.
 
List of Tables
1 Comment syntax . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 Intrinsic data types of variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 Arithmetic operators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 Relational operators (arithmetic and logical) . . . . . . . . . . . . . . . . . . . . . . . . 55 Precedence pecking order . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56 Colon Operator Syntax and its Applications . . . . . . . . . . . . . . . . . . . . . . . . 57 Mathematical functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68 Flow Control Statements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 79 Basic loop constructs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 710
IF
Constructs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 811 Nested
IF
Constructs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 812 Logical
IF-ELSE
Constructs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 813 Logical
IF-ELSE-IF
Constructs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 814 Case Selection Constructs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 915 F90 Optional Logic Block Names . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 916
GO TO
Break-out of Nested Loops . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 917 Skip a Single Loop Cycle . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1018 Abort a Single Loop . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1019 F90
DO
s Named for Control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1020 Looping While a Condition is True . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1121 Function denitions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1122 Arguments and return values of subprograms . . . . . . . . . . . . . . . . . . . . . . . 1223 Dening and referring to global variables . . . . . . . . . . . . . . . . . . . . . . . . . 1224 Bit Function Intrinsics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1225 The ACSII Character Set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1326 F90 Character Functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1327 How to type non-printing characters . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1328 Referencing Structure Components . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1429 Dening New Types of Data Structure . . . . . . . . . . . . . . . . . . . . . . . . . . . 1430 Nested Data Structure Denitions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1431 Declaring, initializing, and assigning components of user-defined datatypes . . . . . . . 1432 F90 Derived Type Component Interpretation . . . . . . . . . . . . . . . . . . . . . . . 1533 Denition of pointers and accessing their targets . . . . . . . . . . . . . . . . . . . . . . 1534 Nullifing a Pointer to Break Association with Target . . . . . . . . . . . . . . . . . . . . 1535 Special Array Characters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1536 Array Operations in Programming Constructs . . . . . . . . . . . . . . . . . . . . . . . 1637 Equivalent Fortran90 and M
ATLAB
Intrinsic Functions . . . . . . . . . . . . . . . . . . 1738 Truncating Numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1839 F90
WHERE
Constructs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1840 F90 Array Operators with Logic Mask Control . . . . . . . . . . . . . . . . . . . . . . 1941 Array initialization constructs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2042 Array initialization constructs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 203
 
LISTOFTABLE
343 Elementary matrix computational routines . . . . . . . . . . . . . . . . . . . . . . . . . 2044 Dynamic allocation of arrays and pointers . . . . . . . . . . . . . . . . . . . . . . . . . 2145 Automatic memory management of local scope arrays . . . . . . . . . . . . . . . . . . . 2146 F90 Single Inheritance Form . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2147 F90 Selective Single Inheritance Form . . . . . . . . . . . . . . . . . . . . . . . . . . . 2248 F90 Single Inheritance Form, with Local Renaming . . . . . . . . . . . . . . . . . . . . 2249 F90 Multiple Selective Inheritance with Renaming . . . . . . . . . . . . . . . . . . . . 22
of 00

Leave a Comment

You must be to leave a comment.
Submit
Characters: ...
You must be to leave a comment.
Submit
Characters: ...