diff --git a/Common/read_snapshot.f90 b/Common/read_snapshot.f90 index 06a3079ea97a29fd8a1951ed007b7d9ba26d1bbd..e747e41cc21f59ebe55e739682a52d8e4bbfbbfb 100644 --- a/Common/read_snapshot.f90 +++ b/Common/read_snapshot.f90 @@ -4,7 +4,7 @@ module read_snapshot_m contains - subroutine read_snapshot(s, hshp, nlon, nlat, k, corner, step, copy) + subroutine read_snapshot(s, hshpc, nlon, nlat, k, corner, step, copy) ! Libraries: use contour_531, only: convert_to_ind @@ -15,7 +15,7 @@ contains use read_eddy_m, only: read_eddy type(snapshot), intent(out):: s ! completely defined - TYPE(shpc), intent(in):: hshp(:) + TYPE(shpc), intent(in):: hshpc(:) integer, intent(in):: nlon, nlat ! size of ssh array in input NetCDF, assuming no repeated point if @@ -39,24 +39,24 @@ contains !--------------------------------------------------------------------- - if (size(hshp) == 1) then + if (size(hshpc) == 1) then i_shpc = 1 else - call hunt([hshp%d0, huge(0)], k, i_shpc) + call hunt([hshpc%d0, huge(0)], k, i_shpc) end if - if (k == hshp(i_shpc)%d0) then + if (k == hshpc(i_shpc)%d0) then ishape_first = 0 else - ! {k > hshp(i_shpc)%d0} - ishape_first = hshp(i_shpc)%ishape_last(k - 1) + 1 + ! {k > hshpc(i_shpc)%d0} + ishape_first = hshpc(i_shpc)%ishape_last(k - 1) + 1 end if - s%number_extr = hshp(i_shpc)%ishape_last(k) - ishape_first + 1 + s%number_extr = hshpc(i_shpc)%ishape_last(k) - ishape_first + 1 allocate(s%list(s%number_extr)) - do ishape = ishape_first, hshp(i_shpc)%ishape_last(k) - call read_eddy(e, date_read, eddy_i, hshp(i_shpc), ishape) + do ishape = ishape_first, hshpc(i_shpc)%ishape_last(k) + call read_eddy(e, date_read, eddy_i, hshpc(i_shpc), ishape) ! Check that all the eddies have the same date index: if (date_read /= k) then