harmonic_analysis module reference

This module computes the harmonic constants which can be used to reconstruct the tidal elevation (or other fields) through SSH = F * x, where F is an nt-by-2*nc matrix (nt is the number of time steps and nc is the number of tidal constituents) containing the cosine/sine functions for each frequency evaluated at each time step, and x is a 2*nc-by-1 vector containing the constant coefficients of the sine/cosine for each constituent (i.e., the harmonic constants). At each grid point, the harmonic constants are computed using least squares,.

More…

Detailed Description

(F' * F) * x = F' * SSH_in,    =>    FtF * x = FtSSH,

where the prime denotes matrix transpose, and SSH_in is the sea surface height (or other fields) determined by the model. The dot products (F’ * F) and (F’ * SSH_in) are computed by accumulating the sums as the model is running and stored in the arrays FtF and FtSSH, respectively. The FtF matrix is inverted as needed before computing and writing out the harmonic constants.

Ed Zaron and William Xu ( chengzhu.xu@oregonstate.edu ), April 2024.