ScaLAPACK  2.0.2
ScaLAPACK: Scalable Linear Algebra PACKage
indxg2l.f
Go to the documentation of this file.
00001       INTEGER FUNCTION INDXG2L( INDXGLOB, NB, IPROC, ISRCPROC, NPROCS )
00002 *
00003 *  -- ScaLAPACK tools routine (version 1.7) --
00004 *     University of Tennessee, Knoxville, Oak Ridge National Laboratory,
00005 *     and University of California, Berkeley.
00006 *     May 1, 1997
00007 *
00008 *     .. Scalar Arguments ..
00009       INTEGER            INDXGLOB, IPROC, ISRCPROC, NB, NPROCS
00010 *     ..
00011 *
00012 *  Purpose
00013 *  =======
00014 *
00015 *  INDXG2L computes the local index of a distributed matrix entry
00016 *  pointed to by the global index INDXGLOB.
00017 *
00018 *  Arguments
00019 *  =========
00020 *
00021 *  INDXGLOB  (global input) INTEGER
00022 *            The global index of the distributed matrix entry.
00023 *
00024 *  NB        (global input) INTEGER
00025 *            Block size, size of the blocks the distributed matrix is
00026 *            split into.
00027 *
00028 *  IPROC     (local dummy) INTEGER
00029 *            Dummy argument in this case in order to unify the calling
00030 *            sequence of the tool-routines.
00031 *
00032 *  ISRCPROC  (local dummy) INTEGER
00033 *            Dummy argument in this case in order to unify the calling
00034 *            sequence of the tool-routines.
00035 *
00036 *  NPROCS    (global input) INTEGER
00037 *            The total number processes over which the distributed
00038 *            matrix is distributed.
00039 *
00040 *  =====================================================================
00041 *
00042 *     .. Intrinsic Functions ..
00043       INTRINSIC          MOD
00044 *     ..
00045 *     .. Executable Statements ..
00046 *
00047       INDXG2L = NB*((INDXGLOB-1)/(NB*NPROCS))+MOD(INDXGLOB-1,NB)+1
00048 *
00049       RETURN
00050 *
00051 *     End of INDXG2L
00052 *
00053       END