Opened 15 years ago

Closed 15 years ago

#349 closed upgrade (Fixed)

4DVar unbalanced error covariance standard deviation scripts

Reported by: arango Owned by: arango
Priority: major Milestone: Matlab Processing Scripts
Component: Matlab Version: 3.3
Keywords: Cc:

Description (last modified by arango)

Added a new directory matlab/4dvar in the Matlab scripts repository containing several scripts to compute the unbalanced standard deviation used to scale 4DVar error covariance. This scripts use the balance operator (K-1) to compute the balanced and unbalanced components. Currently, this directory has the following scripts (see Contents.m):

%
% ROMS 4DVar data assimilation Matlab scripts
% ===========================================
%
% This package contains several generic Matlab scripts to process
% data for ROMS 4DVar data assimilation algorithms.
%
%
% Error Covariance Matrix:
%
%   average:      - Computes the time average of requested NetCDF variable.
%   variance:     - Computes the variance of requested NetCDF variable from
%                     its specified time mean.
%
% Error Covaraince Matrix Balance Operator:
%
%   balance_4dvar - Computes 4DVar balance operator.
%   biconj        - Biconjugate gradient solver for the SSH elliptic
%                     equation.
%   ini_balance   - Initializes balance operator structure array.
%                     It sets internal parameters, reads needed grid
%                     metrics and computes several quantities.
%   lateral_obc   - Sets lateral boundary conditions for a 2D or 3D
%                     field.
%   rho_balance   - Computes balanced density anomaly using a linear
%                     equation of state.
%   s_balance     - Given a temperature anomaly, deltaT=T-Tavg, it
%                     computes balanced salinity anomaly using a T-S
%                     empirical formula.
%   uv_balance    - Computes balanced, baroclinic U- and V-momentum
%                     anomalies (m/s) using the geostrophic balance.
%   zeta_balance  - Computes balanced, baroclinic free-surface anomaly
%                     by solving an elliptical equation OR integrating
%                     the hydrostatic equation from surface to bottom.
%
% Error Covariance Matrix NetCDF file:
%
%   c_std         - Creates 4DVar standard deviation NetCDF file.
%

I also added a new script matlab/utility/nc_getatt.m to read a global or variable attribute from a NetCDF file.

I modified matlab/utility/nc_read.m to have an additional argument, FillValue, to pass the desired value to use when the _FillValue attribute is found in a variable. The default is to replace its value with zero. In some circumstances, like plotting, it is advantageous to set FillValue=NaN to visualize better the land/sea masking or the missing data.

Many thanks to Andy Moore for his great help in coding and testing the 4DVar balance operator in ROMS.

Change History (3)

comment:1 by arango, 15 years ago

Resolution: Done
Status: newclosed

comment:2 by arango, 15 years ago

Description: modified (diff)
Milestone: Release ROMS/TOMS 3.2Matlab Processing Scripts
Resolution: Done
Status: closedreopened

Corrected typo in balance_driver.m. Removed extra character.

comment:3 by arango, 15 years ago

Resolution: Fixed
Status: reopenedclosed
Note: See TracTickets for help on using tickets.