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

Add argument `shp_tr_dir` to `write_aux`

Preparing for two collections of shapefiles.
parent 6aa508b3
No related branches found
No related tags found
No related merge requests found
......@@ -184,6 +184,7 @@ program inst_eddies
CALL shp_tr_close(hshp)
print *, 'Created shapefiles in SHP_triplet.'
call write_aux(corner_deg, step_deg, nlon, nlat, s%number_vis_extr)
call write_aux(corner_deg, step_deg, nlon, nlat, s%number_vis_extr, &
shp_tr_dir = "SHP_triplet")
end program inst_eddies
......@@ -4,7 +4,7 @@ module write_aux_m
contains
subroutine write_aux(corner_deg, step_deg, nlon, nlat, n_shapes)
subroutine write_aux(corner_deg, step_deg, nlon, nlat, n_shapes, shp_tr_dir)
! Write auxiliary files "grid_nml.txt" and "ishape_last.txt".
......@@ -27,6 +27,7 @@ contains
! the grid is global
integer, intent(in):: n_shapes
character(len = *), intent(in):: shp_tr_dir
! Local:
namelist /grid_nml/ corner_deg, step_deg, nlon, nlat
......@@ -35,12 +36,12 @@ contains
!--------------------------------------------------------------------
call new_unit(unit)
open(unit, file = "SHP_triplet/grid_nml.txt", status = "replace", &
open(unit, file = shp_tr_dir // "/grid_nml.txt", status = "replace", &
action = "write")
write(unit, nml = grid_nml)
close(unit)
open(unit, file = "SHP_triplet/ishape_last.txt", status = "replace", &
open(unit, file = shp_tr_dir // "/ishape_last.txt", status = "replace", &
action = "write")
write(unit, fmt = *) n_shapes - 1
close(unit)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment