psmile_extract_indices_3d_dble.F90

Go to the documentation of this file.
00001 !-----------------------------------------------------------------------
00002 ! Copyright 2006-2010, NEC Europe Ltd., London, UK.
00003 ! All rights reserved. Use is subject to OASIS4 license terms.
00004 !-----------------------------------------------------------------------
00005 !BOP
00006 !
00007 ! !ROUTINE: PSMILe_Extract_indices_3d_dble
00008 !
00009 ! !INTERFACE:
00010 
00011       subroutine psmile_extract_indices_3d_dble (array, shape, &
00012                dstijk, ncpl, dest_vector, ierror)
00013 !
00014 ! !USES:
00015 !
00016       use PRISM_constants
00017 !
00018       use PSMILe, dummy_interface => PSMILe_Extract_indices_3d_dble
00019 
00020       implicit none
00021 !
00022 ! !INPUT PARAMETERS:
00023 !
00024       Integer, Intent (In)            :: shape (2, ndim_3d)
00025 !
00026 !     Shape of the array "array"
00027 !
00028       Double Precision, Intent (In)   :: array (shape(1,1):shape(2,1), 
00029                                                 shape(1,2):shape(2,2), 
00030                                                 shape(1,3):shape(2,3))
00031 !
00032       Integer, Intent (In)            :: ncpl
00033 !
00034 !     Dimension of output vector "dest_vector" and input vector "dstijk"
00035 !
00036       Integer, Intent (In)            :: dstijk (ndim_3d, ncpl)
00037 !
00038 ! !OUTPUT PARAMETERS:
00039 !
00040       Double Precision, Intent (Out)  :: dest_vector (ncpl)
00041 !
00042 !     Output vector containing extracted values of indices "dstijk"
00043 !
00044       Integer, Intent (Out)           :: ierror
00045 
00046 !     Returns the error code of PSMILE_Extract_indices_3d_dble;
00047 !             ierror = 0 : No error
00048 !             ierror > 0 : Severe error
00049 !
00050 ! !LOCAL VARIABLES
00051 !
00052 !     ... for extracting the compact list
00053 !
00054       Integer                         :: n
00055 !
00056 ! !DESCRIPTION:
00057 !
00058 ! Subroutine "PSMILe_Extract_indices_3d_dble" extracts the values of array
00059 ! "array" for indices specified in "dstijk" and stores the values in
00060 ! destination vector "dest_vector"
00061 !
00062 ! !REVISION HISTORY:
00063 !
00064 !   Date      Programmer   Description
00065 ! ----------  ----------   -----------
00066 ! 03.07.21    H. Ritzdorf  created
00067 !
00068 !EOP
00069 !----------------------------------------------------------------------
00070 !
00071 !  $Id: psmile_extract_indices_3d_dble.F90 2325 2010-04-21 15:00:07Z valcke $
00072 !  $Author: valcke $
00073 !
00074    Character(len=len_cvs_string), save :: mycvs = 
00075        '$Id: psmile_extract_indices_3d_dble.F90 2325 2010-04-21 15:00:07Z valcke $'
00076 !
00077 !----------------------------------------------------------------------
00078 !
00079 !  Initialization
00080 !
00081 #ifdef VERBOSE
00082       print 9990, trim(ch_id)
00083 
00084       call psmile_flushstd
00085 #endif /* VERBOSE */
00086 !
00087 #ifdef PRISM_ASSERTION
00088 #endif
00089 !
00090       ierror = 0
00091 !
00092 !cdir vector
00093          do n = 1, ncpl
00094          dest_vector (n) = array (dstijk(1, n), &
00095                                   dstijk(2, n), &
00096                                   dstijk(3, n))
00097          end do
00098 !
00099 !===> All done
00100 !
00101 #ifdef VERBOSE
00102       print 9980, trim(ch_id)
00103 
00104       call psmile_flushstd
00105 #endif /* VERBOSE */
00106 !
00107 !  Formats:
00108 !
00109 9990 format (1x, a, ': psmile_extract_indices_3d_dble')
00110 9980 format (1x, a, ': psmile_extract_indices_3d_dble: eof')
00111 
00112       end subroutine PSMILe_Extract_indices_3d_dble

Generated on 18 Mar 2011 for Oasis4 by  doxygen 1.6.1