1 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
2 | % |
---|
3 | % Make 1 plot from the results of the OVERFLOW test case |
---|
4 | % |
---|
5 | % Further Information: |
---|
6 | % http://www.brest.ird.fr/Roms_tools/ |
---|
7 | % |
---|
8 | % This file is part of ROMSTOOLS |
---|
9 | % |
---|
10 | % ROMSTOOLS is free software; you can redistribute it and/or modify |
---|
11 | % it under the terms of the GNU General Public License as published |
---|
12 | % by the Free Software Foundation; either version 2 of the License, |
---|
13 | % or (at your option) any later version. |
---|
14 | % |
---|
15 | % ROMSTOOLS is distributed in the hope that it will be useful, but |
---|
16 | % WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
17 | % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
---|
18 | % GNU General Public License for more details. |
---|
19 | % |
---|
20 | % You should have received a copy of the GNU General Public License |
---|
21 | % along with this program; if not, write to the Free Software |
---|
22 | % Foundation, Inc., 59 Temple Place, Suite 330, Boston, |
---|
23 | % MA 02111-1307 USA |
---|
24 | % |
---|
25 | % Copyright (c) 2002-2006 by Pierrick Penven |
---|
26 | % e-mail:Pierrick.Penven@ird.fr |
---|
27 | % |
---|
28 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
29 | clear all |
---|
30 | close all |
---|
31 | |
---|
32 | tndx=3; |
---|
33 | % |
---|
34 | % Read data |
---|
35 | % |
---|
36 | nc=netcdf('roms_his.nc'); |
---|
37 | h=nc{'h'}(:); |
---|
38 | y=squeeze(nc{'y_rho'}(:,2)); |
---|
39 | zeta=squeeze(nc{'zeta'}(tndx,:,:)); |
---|
40 | t=squeeze(nc{'temp'}(tndx,:,:,2)); |
---|
41 | [N,M]=size(t); |
---|
42 | theta_s=nc.theta_s(:); |
---|
43 | theta_b=nc.theta_b(:); |
---|
44 | hc=nc.hc(:); |
---|
45 | close(nc); |
---|
46 | |
---|
47 | zr = zlevs(h,zeta,theta_s,theta_b,hc,N,'r'); |
---|
48 | zr=squeeze(zr(:,:,1)); |
---|
49 | yr=reshape(y,1,M); |
---|
50 | yr=repmat(yr,[N 1])/1000; |
---|
51 | |
---|
52 | contourf(yr,zr,t,(-0.1:0.02:1)) |
---|
53 | caxis([0 1]) |
---|
54 | shading flat |
---|
55 | colorbar |
---|
56 | title('Overflow sigma-t vertical section') |
---|
57 | |
---|
58 | |
---|
59 | |
---|