Ocean Modeling Discussion

ROMS/TOMS

Search for:
It is currently Thu Mar 23, 2017 8:12 pm




Post new topic Reply to topic  [ 2 posts ] 

All times are UTC

Author Message
PostPosted: Mon Mar 09, 2009 1:19 am 
Offline
Site Admin
User avatar

Joined: Wed Feb 26, 2003 4:41 pm
Posts: 999
Location: IMCS, Rutgers University
I am releasing few Matlab pre- and post-processing scripts for ROMS. These scripts are well documented. Notice that each sub-directory has their own Contents.m which briefly describe each m-file within. It is highly recommended for you to use the provided startup.m or modify your starting workspaced script and include these paths so Matlab can find them.

Currently, the matlab repository (https://www.myroms.org/svn/src/matlab) have the following sub-directory structure:
Code:
matlab/                       Main repository directory
      /bathymetry             Bathymetry extracting tools
      /coastlines             Coastline extracting tools
      /landmask               ROMS Land/Sea mask tools and GUIs
      /seagrid/               Charles Denham grid generation GUI
              /@seagrid       SeaGrid internal utility functions
              /test_data      SeaGrid test data
      /seawater               Phillip Morgan (CSIRO) SeaWater library
      /utility                Generic pre- and post-processing library
      /startup.m              Workspace configuration script


Some Remarks:

  • To check-out the files from the matlab repository (latest version), enter (notice https instead of http):
    Code:
         svn checkout https://www.myroms.org/svn/src/matlab MyDir
    or
         svn checkout --username joe_roms https://www.myroms.org/svn/src/matlab MyDir

  • The script utility/depths.m is the official Matlab script to compute ROMS depths for any 3D-variable. I highly recommend to you to use this script. Recall, that the depths (z_r and z_w) in ROMS change at each time step because of its dependency on the time-varying free-surface. See :arrow: WikiROMS description of ROMS Vertical S-coordinate.

  • The script utility/scoord.m can be used to select the optimal set of vertical stretching parameters, vertical transformation equation, and vertical stretching function for a particular applications. See :arrow: WikiROMS for more details. This script was used to produce the plots shown in this wiki page.

  • The NetCDF interface to Matlab is via the :arrow: MEXNC developed by John Evans. MEXNC is a mex-file interface very similar to the NetCDF C-library. John Evans developed a very clever design (starting with version 2.9.1) for this interface. It performs a series of internal checks to either use Matlab native interface (available in version R2008b) or the MEXNC library. MEXNC It is possible to compile MEXNC to support both NetCDF-3 and NetCDF4/HDF5 type files.

  • It is possible to build an OpenDAP enabled MEXNC. There are notes online :arrow: here. Unfortunately, you won't be able read NetCDF4/HDF5 files though. We are investigating whether MEXNC can be modified to use the NetCDF-Java library for reading OpenDAP URLs.
    Mark Hadfield remind me that there is an experimental version of OpenDAP in the latest version of the NetCDF4 library. It has the ncdump/ncgen utilility that can read files from an OpenDAP server and read/write NetCDF-4 files. He also adds:
    Quote:
    The only problem, a fairly big one, is that the OpenDAP interface is written in C++, which means that programs (like MEXNC, Fortran programs, etc) that use this library must be linked with the C++ linker. This just isn't worth the bother to me, so I haven't tried to link to it with ROMS. However the netCDF developers plan to reqrite the OpenDAP code in C for version 4.1. I don't know when they plan to release 4.1, but it won't be soon.


Top
 Profile  
Reply with quote  
PostPosted: Tue Mar 10, 2009 3:01 am 
Offline
User avatar

Joined: Mon Apr 28, 2003 5:44 pm
Posts: 392
Location: Rutgers University
The CSIRO Matlab seawater toolbox is available directly from http://www.cmar.csiro.au/datacentre/ext_docs/seawater.htm where is it up to version 3.2. I have no idea to what extent this code might have changed from the versions Hernan has placed in the ROMS repository, but users should know there is a more recent source.

_________________
John Wilkin: IMCS Rutgers University
71 Dudley Rd, New Brunswick, NJ 08901-8521, USA. ph: 609-630-0559 jwilkin@rutgers.edu


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group