Hi SCHISM group,
I may found a bug in SCHISM-WWM coupling when trying to output hotstart records for the WWM model. The tag version I used is v5.13.0.
My model runs normally if I choose to not save hotstart for WWM, but it crashes due to "start + count of out bound" if I turn on LHOTF in wwminput.nml. The model can still run for 1 time step, but it crashes at the first "starting WWM".
After some debug, I found the reason. My SCHISM mesh has quads, but as you know, WWM only supports triangle elements. The issue is that the total element in SCHISM and WWM grids are different.
To solve it, in wwm_hotfile.F90, go to the subroutine "SUBROUTINE OUTPUT_HOTFILE_NETCDF", change ne_global to ne_total:
#ifdef MPI_PARALL_GRID
IF (MULTIPLEOUT_HOT.eq.0) THEN
np_write=np_global
- ne_write=ne_global
+ ne_write=ne_total ! changed by Zhiyun Du
ELSE
np_write=MNP
ne_write=MNE
ENDIF
#else
np_write=np_global
- ne_write=ne_global
+ ne_write=ne_total ! changed by Zhiyun Du
#endif
Hi SCHISM group,
I may found a bug in SCHISM-WWM coupling when trying to output hotstart records for the WWM model. The tag version I used is v5.13.0.
My model runs normally if I choose to not save hotstart for WWM, but it crashes due to "start + count of out bound" if I turn on LHOTF in wwminput.nml. The model can still run for 1 time step, but it crashes at the first "starting WWM".
After some debug, I found the reason. My SCHISM mesh has quads, but as you know, WWM only supports triangle elements. The issue is that the total element in SCHISM and WWM grids are different.
To solve it, in wwm_hotfile.F90, go to the subroutine "SUBROUTINE OUTPUT_HOTFILE_NETCDF", change ne_global to ne_total: