内潮动力模态分解(dynamical modal decomposition for internal tides)
网络上似乎没有公开的内潮模态分解程序,笔者根据论文 Extraction of Internal Tidal Currents and Reconstruction of Full-Depth Tidal Currents from Mooring Observations (Cao et al., 2015)以及相关的视频报告(https://www.bilibili.com/video/BV15L411K7iG?spm_id_from=333.880),编写了s_modaldecomposition 函数,可以做内潮的动力模态分解,该函数添加到了最新的s_tide v1.23 update 4版本里(下载链接:https://www.researchgate.net/project/A-non-stationary-tidal-analysis-toolbox-S-TIDE),

下面是这个函数的一个例子,无论是从时间上还是空间上,模态分解和重构的效果都很不错。
load data.mat;
% u_k1 means u speed for K1 tide
[N,Fi,dFi,mc,um]=s_modaldecomposition(depth,density,u_k1,4); % 4 baroclinic modes
%um(5,:,:) is the barotropic mode
i=1900; plot(squeeze(um(4,:,i)+um(5,:,i)+um(3,:,i)+um(2,:,i)+um(1,:,i)),depth,'k')
set(gca,'YDir','reverse');hold on; plot(u_k1(:,i),depth,'r*')
ylabel('Depth(m)');xlabel('u(m/s)');
legend('reconstructed','observed')

d=18;
plot(squeeze(um(4,d,:)+um(5,d,:)+um(3,d,:)+um(2,d,:)+um(1,d,:)),'k*')
hold on;plot(u_k1(d,:),'r');xlim([1 100])
ylabel('u(m/s)');xlabel('Time(hour)');
title('Depth: 85m');legend('reconstructed','observed')
