/************************************************************
  This example illustrates the concept of virtual dataset I/O
  The program  creates 2-dim source dataset and writes
  data to it. Then it creates 2-dim virtual dataset that has
  the same dimension sizes and maps the all elements of the 
  virtual dataset to all elements of the source dataset.
  Then VDS is read back.
  This file is intended for use with HDF5 Library version 1.10
 ************************************************************/
/* EIP Add link to the picture */
#include "hdf5.h"
#include <stdio.h>
#include <stdlib.h>
#define FILE         "vds-simpleIO.h5"
#define DATASET      "VDS"
#define DIM1            6
#define DIM0            4 
#define RANK            2
#define SRC_FILE      "a.h5"
#define SRC_DATASET    "/A"
int
main (void)
{
    hid_t        file, space, src_space, vspace, dset; /* Handles */ 
    hid_t        dcpl;
    herr_t       status;
    hsize_t      vdsdims[2] = {DIM0, DIM1},     /* Virtual dataset dimension */
                 dims[2] = {DIM0, DIM1};        /* Source dataset dimensions */
    int          wdata[DIM0][DIM1],             /* Write buffer for source dataset */
                 rdata[DIM0][DIM1],             /* Read buffer for virtual dataset */
                 i, j;  
    H5D_layout_t layout;                        /* Storage layout */
    size_t       num_map;                       /* Number of mappings */
    ssize_t      len;                           /* Length of the string; also a return value */
    char         *filename;                  
    char         *dsetname;
    /*
     * Initialize data.
     */
        for (i = 0; i < DIM0; i++) 
            for (j = 0; j < DIM1; j++) wdata[i][j] = i+1;
         
     /*