Skip to content
Snippets Groups Projects
Commit d73982b0 authored by Lionel GUEZ's avatar Lionel GUEZ
Browse files

Introduce variable `first_slice`

It will change if the user chooses a slice.
parent bdbe87ac
No related branches found
No related tags found
No related merge requests found
......@@ -20,7 +20,7 @@ program eddy_graph
implicit none
integer rank, n_proc, delta, i, j, iostat
integer rank, n_proc, delta, i, j, iostat, first_slice
integer:: n_dates = huge(0) ! number of dates to read
integer k ! date index
integer k_begin, k_end, k_end_main_loop
......@@ -53,6 +53,8 @@ program eddy_graph
read(unit = *, nml = main_nml)
write(unit = *, nml = main_nml)
first_slice = 0
! Read n_slices:
call new_unit(unit)
......@@ -73,11 +75,12 @@ program eddy_graph
end if
call ezmpi_bcast(n_slices, root = 0)
call ezmpi_bcast(first_slice, root = 0)
allocate(hshpc(n_slices), ssm(n_slices))
do i = 1, n_slices
call shpc_open(hshpc(i), trim(shpc_dir), cyclone = cyclone, &
slice = i - 1, pszaccess = "rb")
slice = first_slice + i - 1, pszaccess = "rb")
call dbf_read_attribute_03(ssm(i)%d0, hshpc(i)%extremum, &
hshpc(i)%extr_date, ishape = 0)
call read_opcol(ssm(i)%ishape_last, hshpc(i)%unit, my_lbound = ssm(i)%d0)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment