This README.txt file was generated on 9 MAR 2022 by Sam Kelly ------------------------ GENERAL INFORMATION ------------------------ These are the configuration files for the MIT general circulation model (MITgcm, v 1.1936 2013/11/05, http://mitgcm.org/). The model is extensively documented online. There are two sub-folders within the MITgcm folder that contain all the setup information needed for each type of run: (1) bump: oscillating flow over a coastal bump (2) Oregon: K1 barotropic tidal velocities over the Oregon continental slope The standard folders within each run are: (1) build: all compile-time options for the MITgcm (read with model is compiled) (2) input: all run-time options for the MITgcm (read when model is executed) (3) matlab: all Matlab codes used to create input files (gendata.m) and process the output files (main.m) Only the Matlab scripts and functions are unique and documented here. ------------------------------------ SCRIPT DESCRIPTION OF gendata.m ------------------------------------ Writes input files that are read when MITgcm is executed Function dependencies: CTW_modes.m LAT2KM.m LON2KM.m satbath.m TPXO.m Input files: strat.mat Output files: data.mat Binary output files (read by MITgcm): delXvar delYvar delZvar tRefvar topog.init T.init EU.ob EV.ob ET.ob NU.ob NV.ob NT.ob SU.ob SV.ob ST.ob WU.ob WU.ob WT.ob ------------------------------------ SCRIPT DESCRIPTION OF main.m ------------------------------------ Post-processes all of the MITgcm ouput files. Combines relevant data into small MAT files that can be easily read and plotted. Function dependencies: post_process.m Input: none Output files: mit_L.mat mit_W.mat ------------------------------------ SCRIPT DESCRIPTION OF post_process.m ------------------------------------ Post-processes a single MITgcm simulation run. Reads data and projects them onto mode. Function dependencies: CTW_modes.m Input: folder (MITgcm output directory path) Input files: data.mat (produced by gendata.m) MITgcm NetCDF output files Output files: data_post.mat ------------------------------------ FUNCTION DESCRIPTION OF CSW_modes.m ------------------------------------ see function header ------------------------------------ FUNCTION DESCRIPTION OF LAT2KM.m ------------------------------------ Input: None Output: The number of kilometers per degree of latitude. ------------------------------------ FUNCTION DESCRIPTION OF LON2KM.m ------------------------------------ Input: Latitude [deg] Output: The number of kilometers per degree of longitude. ------------------------------------ FUNCTION DESCRIPTION OF satbath.m ------------------------------------ Builtin matlab function to read the Smith & Sandwell global bathymetry. This function was modified on lines 98-99 and 120 to read the 1-minute bathymetry file (topo_8.2.img). See Matlab documentation for inputs and outputs. File dependency (available at https://topex.ucsd.edu/marine_topo/): topo_8.2.img ------------------------------------ FUNCTION DESCRIPTION OF TPXO.m ------------------------------------ Reads the NetCDF TPXOO8 atlas and returns the amplitudes of the tidal transports and elevations at each lon and lat. The amplitudes can be used to predict the tides for a given constituent using the formula: U(x,y,t)=Real[U(x,y)*exp(ii*omega*t)] where t is seconds from the start of the input day Input: lon [m x 1] or [m x n] Vector of longitudes [0 360] lat [n x 1] or [m x n] Vector of latitudes [-90 90] conID [k x 1] Constituents to include (e.g., see list below, [1 3] returns M2 and K1) day [1 x 1] The serial day (use 'datenum') for which the phase is set to zero vel_flag (0 or 1) If 0 (default) return transports, if 1 return velocity Output: U, V [m x n x k] Complex amplitude of transport [m^2/s] eta [m x n x k] Complex amplitude of tidal elevation [m] omega [k x 1] The tidal frequency in rad/s File dependencies (available at https://www.tpxo.net/): uv.k1_tpxo8_atlas_30c.nc hf.k1_tpxo8_atlas_30c.nc grid_tpxo8atlas_30.nc