subroutine ReadArray_HDF5_real_r3_parallel(fileId,arrayName,hfArray,offset)
implicit none
integer(HID_T),intent(in) :: fileId
character(*),intent(in) :: arrayName
integer(HID_T),intent(in) :: offset(1:3)
real(prec),dimension(:,:,:),intent(inout) :: hfArray
! Local
integer(HID_T) :: plistId
integer(HID_T) :: dsetId
integer(HID_T) :: dtypeId
integer(HID_T) :: filespace
integer(HID_T) :: memspace
integer(HID_T) :: dims(1:3)
integer :: error
dims = shape(hfArray)
call h5screate_simple_f(3,dims,memspace,error)
call h5dopen_f(fileId,arrayName,dsetId,error)
call h5dget_space_f(dsetId,filespace,error)
call h5sselect_hyperslab_f(filespace,H5S_SELECT_SET_F,offset,dims,error)
call h5pcreate_f(H5P_DATASET_XFER_F,plistId,error)
call h5pset_dxpl_mpio_f(plistId,H5FD_MPIO_COLLECTIVE_F,error)
call h5dget_type_f(dsetId,dtypeId,error)
call h5dread_f(dsetId,dtypeId,hfArray,dims, &
error,memspace,filespace,plistId)
call h5tclose_f(dtypeId,error)
call h5pclose_f(plistId,error)
call h5sclose_f(filespace,error)
call h5dclose_f(dsetId,error)
call h5sclose_f(memspace,error)
endsubroutine ReadArray_HDF5_real_r3_parallel