DOI-USGS / DOI-USGS/COAWST

Unable to read swan output file in WRF-SWAN-ROMS coupling simulation

Open
#396 6 comments 0 reactions 0 assignees View on GitHub
Dominant language
Fortran
Stars
156
Forks
75
PR merge metrics
No merged PRs in 30d

Description

Hello.

I am trying to conduct a mesoscale WRF-SWAN-ROMS coupling simulation.

### However, the SWAN output file from WRF-SWAN-ROMS could not be read by matlab using command: "load('scs_xp.mat')"

### the error is below:
"
>> load('scs_yp.mat')
Error using load
Unable to read MAT-file
/usr/local/1_software/Build_COAWST/COAWSTCoupled_202505251400_ROMSN40_tB0.5/Projects/0/s3out/scs_yp.mat. File
might be corrupt.

"

I tried to generate the files in the mat and nedcdf formats, but they do not work.

### Specifically, the output nc file and matlab file in SWAN-only simulations could be extracted !!!!!!

The attachment is my SWAN input and compile files.

Are there any problems?

My system is: ubuntu20.04 lts and gcc 9.4.0

[a_swan.in.txt](https://github.com/user-attachments/files/20515605/a_swan.in.txt)
[build_coawst.sh.txt](https://github.com/user-attachments/files/20515607/build_coawst.sh.txt)
[wsr.h.txt](https://github.com/user-attachments/files/20515606/wsr.h.txt)

Contributor guide

Open the contributing guide

Research direction

Start by reviewing a_swan.in.txt, build_coawst.sh.txt, and wsr.h.txt, then reproduce the coupled run and test load('scs_yp.mat'). Compare the generated MAT and NetCDF files with those from the SWAN-only simulation. Done means the WRF-SWAN-ROMS output files are valid and readable in MATLAB.

Written by the indexing model from the issue text.

Assessment

Tech stack
fortran, matlab
Domain
hpc
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.