%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % Make 1 plot from the results of the OVERFLOW test case % % Further Information: % http://www.brest.ird.fr/Roms_tools/ % % This file is part of ROMSTOOLS % % ROMSTOOLS is free software; you can redistribute it and/or modify % it under the terms of the GNU General Public License as published % by the Free Software Foundation; either version 2 of the License, % or (at your option) any later version. % % ROMSTOOLS is distributed in the hope that it will be useful, but % WITHOUT ANY WARRANTY; without even the implied warranty of % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the % GNU General Public License for more details. % % You should have received a copy of the GNU General Public License % along with this program; if not, write to the Free Software % Foundation, Inc., 59 Temple Place, Suite 330, Boston, % MA 02111-1307 USA % % Copyright (c) 2002-2006 by Pierrick Penven % e-mail:Pierrick.Penven@ird.fr % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% clear all close all tndx=3; % % Read data % nc=netcdf('roms_his.nc'); h=nc{'h'}(:); y=squeeze(nc{'y_rho'}(:,2)); zeta=squeeze(nc{'zeta'}(tndx,:,:)); t=squeeze(nc{'temp'}(tndx,:,:,2)); [N,M]=size(t); theta_s=nc.theta_s(:); theta_b=nc.theta_b(:); hc=nc.hc(:); close(nc); zr = zlevs(h,zeta,theta_s,theta_b,hc,N,'r'); zr=squeeze(zr(:,:,1)); yr=reshape(y,1,M); yr=repmat(yr,[N 1])/1000; contourf(yr,zr,t,(-0.1:0.02:1)) caxis([0 1]) shading flat colorbar title('Overflow sigma-t vertical section')