HP Fortran Programmer's Reference (September 2007)
Introduction to HP Fortran
HP Fortran features
Chapter 136
Arrays
The Fortran 90 standard has defined these new array features:
❏ Array sections that permit operations for processing whole arrays or a subset of array
elements; expressions, functions, and assignments can be array-valued. The WHERE
construct and statement are used for masked-array assignment.
❏ Array constructors—unnamed, rank-one arrays whose elements can be constants or
variables. You can use the RESHAPE intrinsic function to transform the array constructor
to an array value of higher rank.
❏ New types of array:
— Assumed-shape arrays are dummy arguments that take on the size and shape of the
corresponding actual arguments.
— Deferred-shape arrays become defined when they are associated with target array
objects.
— Automatic arrays have at least one bound that is not a constant.
Arrays are discussed in Chapter 3, “Arrays,” on page 55.
Control constructs
Control constructs
❏ The CASE construct selects and executes one or more associated statements on the basis of
a case selector value, which can be of type INTEGER, CHARACTER or LOGICAL.
❏ Additional forms of the DO statement allow branching to the end of a DO loop and
branching out of a DO loop.
These constructs are described in “Control constructs and statement blocks” on page 139.
Operators
You can write your own procedures to define new operations for intrinsic operators, including
assignment, for use with operands of intrinsic data types or derived data types; see “Defined
operators” on page 185 and “Defined assignment” on page 187.