Changeset 3fbbfbb for utilities.f


Ignore:
Timestamp:
06/16/10 08:25:47 (14 years ago)
Author:
Jan Meinke <j.meinke@…>
Branches:
master
Children:
5fef0d7
Parents:
9f146fa
Message:

Move to doxygen comments and smmp_p.

Doxygen comments in Fortran are !> ... !! ... !<. I'm planning move the API documentation from the
lyx file into the code. This should make it easier to get documentation for all the common block
variables as well.

Use import smmp_p to indicate the parallel version of the Python bindings.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • utilities.f

    r9f146fa r3fbbfbb  
    77! *********************************************************************
    88
    9 !! Calculate the best way to distribute the work load across processors.
    10 !  It calculates the average number of interactions and then tries to
    11 !  assign a number of interactions to each processor that is as close
    12 !  as possible to the average. The routine should be called once for
    13 !  every molecule in the system.
    14 !
    15 !  @param num_ppr Number of processors per replica
    16 !  @param nml index of molecule or zero.
    17 !
    18 !  @author Jan H. Meinke
     9!> Calculate the best way to distribute the work load across processors.
     10!!  It calculates the average number of interactions and then tries to
     11!!  assign a number of interactions to each processor that is as close
     12!!  as possible to the average. The routine should be called once for
     13!!  every molecule in the system.
     14!!
     15!!  @param num_ppr Number of processors per replica
     16!!  @param nml index of molecule or zero.
     17!!
     18!!  @author Jan H. Meinke
     19!<
    1920      subroutine distributeWorkLoad(num_ppr,nml)
    2021
     
    117118      end subroutine distributeWorkLoad
    118119
    119 !-----------------------------------------------------------------------
    120 !     The function fileNameMP takes a template of a file name in the
    121 !     variable base. The position of the first and last character that
    122 !     may be replaced by rank in the string are given in i1 (first) and
    123 !     i2 (last).
    124 !     The function returns an empty string if the rank would need more
    125 !     characters than is allowed by the template.
    126 !     For example,
    127 !     \code
    128 !     rank = 11
    129 !     fileName = fileNameMP('base_0000.dat', 6, 9, rank)
    130 !     write (logString, *), fileName
    131 !     \endcode
    132 !     will output base_0011.dat.
    133 !
    134 !     @param base the base file name, e.g., base_0000.dat.
    135 !     @param i1 index of the first character that may be replaced
    136 !     @param i2 index of the last character that may be replaced
    137 !     @param rank the number that should be inserted into the file name.
    138 !
    139 !     @return file name for rank
    140 !-----------------------------------------------------------------------
     120!>
     121!!     The function fileNameMP takes a template of a file name in the
     122!!     variable base. The position of the first and last character that
     123!!     may be replaced by rank in the string are given in i1 (first) and
     124!!     i2 (last).
     125!!     The function returns an empty string if the rank would need more
     126!!     characters than is allowed by the template.
     127!!     For example,
     128!!     \code
     129!!     rank = 11
     130!!     fileName = fileNameMP('base_0000.dat', 6, 9, rank)
     131!!     write (logString, *), fileName
     132!!     \endcode
     133!!     will output base_0011.dat.
     134!!
     135!!     @param base the base file name, e.g., base_0000.dat.
     136!!     @param i1 index of the first character that may be replaced
     137!!     @param i2 index of the last character that may be replaced
     138!!     @param rank the number that should be inserted into the file name.
     139!!
     140!!     @return file name for rank
     141!<
    141142      character*80 function fileNameMP(base, i1, i2, rank)
    142143
     
    172173
    173174
    174 !----------------------------------------------------------------------
    175 !     Add messages to log. This routine takes the log (debugging) mes-
    176 !     sages and writes them to the log file if the log level is less or
    177 !     equal to the maximum log level given by the global variable
    178 !     MAXLOGLEVEL.
    179 !
    180 !     @author Jan H. Meinke
    181 !
    182 !     @param loglevel level at which this message should be added to
    183 !            the log.
    184 !     @param message message to be written to the log.
    185 !     @param rank global rank of this node if running an MPI job zero
    186 !            otherwise.
    187 !----------------------------------------------------------------------
     175!>
     176!!     Add messages to log. This routine takes the log (debugging) mes-
     177!!     sages and writes them to the log file if the log level is less or
     178!!     equal to the maximum log level given by the global variable
     179!!     MAXLOGLEVEL.
     180!!
     181!!     @author Jan H. Meinke
     182!!
     183!!     @param loglevel level at which this message should be added to
     184!!            the log.
     185!!     @param message message to be written to the log.
     186!!     @param rank global rank of this node if running an MPI job zero
     187!!            otherwise.
     188!<
    188189      subroutine addLogMessage(loglevel, message, rank)
    189190
    190       integer maxloglevel, logfileunit
     191         integer MAXLOGLEVEL, LOGFILEUNIT
     192         common /log/MAXLOGLEVEL, LOGFILEUNIT
    191193
    192194         integer :: loglevel, rank
Note: See TracChangeset for help on using the changeset viewer.