Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix WW3 failing restart #160

Merged
merged 2 commits into from
May 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion WW3/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@ target_sources(OM3_ww3 PRIVATE
WW3/model/src/w3iogomd.F90
WW3/model/src/w3iogrmd.F90
WW3/model/src/w3iopomd.F90
WW3/model/src/w3iorsmd.F90
WW3/model/src/w3iosfmd.F90
WW3/model/src/w3iotrmd.F90
WW3/model/src/w3macros.h
Expand Down Expand Up @@ -94,6 +93,8 @@ target_sources(OM3_ww3 PRIVATE
${switch_files}
)

add_patched_source(OM3_ww3 WW3/model/src/w3iorsmd.F90)

## Utilities

# ww3_grid
Expand Down
22 changes: 22 additions & 0 deletions WW3/patches/w3iorsmd.F90.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
diff --git a/w3iorsmd.F90 b/w3iorsmd.F90.new
index ffb34d47..0e32748b 100644
--- a/w3iorsmd.F90
+++ b/w3iorsmd.F90.new
@@ -893,7 +893,7 @@ CONTAINS
WRITEBUFF(:) = 0.
WRITE (NDSR,POS=RPOS,ERR=803,IOSTAT=IERR) WRITEBUFF
WRITE (NDSR,POS=RPOS,ERR=803,IOSTAT=IERR) &
- TLEV, TICE, TRHO
+ TLEV, TICE, TRHO, TIC1, TIC5
DO IPART=1,NPART
NREC = NREC + 1
RPOS = 1_8 + LRECL*(NREC-1_8)
@@ -1078,7 +1078,7 @@ CONTAINS
IF (TYPE.EQ.'FULL') THEN
RPOS = 1_8 + LRECL*(NREC-1_8)
READ (NDSR,POS=RPOS,ERR=802,IOSTAT=IERR) &
- TLEV, TICE, TRHO
+ TLEV, TICE, TRHO, TIC1, TIC5
DO IPART=1,NPART
NREC = NREC + 1
RPOS = 1_8 + LRECL*(NREC-1_8)
Loading