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...

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

DescriptionA unit may be the subject of a CLOSE statement from within any program unit. If the unitspecified does not exist or has no file connected to it the use of the CLOSE statement has noeffect. Provided the file is still in existence it may be reconnected to the same or a different unitafter the execution of a CLOSE statement. Note that an implicit CLOSE is executed when aprogram stops.ExampleIn the following example, the file on UNIT 6 is closed and <strong>del</strong>eted.CLOSE(UNIT=6,STATUS='DELETE')COMMON 77The COMMON statement defines global blocks of storage that are either sequential or nonsequential. There are two forms of the COMMON statement, a static form and a dynamic form.Each common block is identified by the symbolic name defined in the COMMON block.SyntaxCOMMON /[name ] /nlist [, /name/nlist]...name is the name of each common block and is declared between the /.../<strong>del</strong>imiters for a named common and with no name for a blank common.nlistis a list of variable names where arrays may be defined inDIMENSION statements or formally declared by their inclusion in theCOMMON block.Common Block Rules and BehaviorsA common block is a global entity. Any common block name (or blank common) can appear morethan once in one or more COMMON statements in a program unit. The following is a list of rulesassociated with common blocks:Blank Common The name of the COMMON block need not be supplied; without aname, the common is a BLANK COMMON. In this case the compileruses a default name.Same Names There can be several COMMON block statements of the same name ina program segment; these are effectively treated as one statement, withvariables concatenated from one COMMON statement of the sameFortran Statements 65

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

Saved successfully!

Ooh no, something went wrong!