Documentation of surf_wind_compare


Global Index (short | long) | Local contents | Local Index (short | long)


Help text

  Load GR pattern and time series

Cross-Reference Information

This script calls

Listing of script surf_wind_compare



cd /home/disk/hayes2/dvimont/ccm/ccm3.6/data
load ct_gr.mat;

%  Get CCM data:

cd /home/disk/tao/dvimont/matlab/CCM/GR
filin = 'wgr.nc';
nc = netcdf(filin, 'nowrite');
  uw = nc{'U'}(1:3,:,:,:);
  vw = nc{'V'}(1:3,:,:,:);
  txw = -1 * nc{'TAUX'}(1:3,:,:);
  tyw = -1 * nc{'TAUY'}(1:3,:,:);
  psw = nc{'PS'}(1:3,:,:);
  tsw = nc{'TS'}(1:3,:,:);
nc = close(nc);

filin = 'cgr.nc';
nc = netcdf(filin, 'nowrite');
  uc = nc{'U'}(1:3,:,:,:);
  vc = nc{'V'}(1:3,:,:,:);
  txc = -1 * nc{'TAUX'}(1:3,:,:);
  tyc = -1 * nc{'TAUY'}(1:3,:,:);
  psc = nc{'PS'}(1:3,:,:);
  tsc = nc{'TS'}(1:3,:,:);
  lat  = nc{'lat'}(:);
  lon  = nc{'lon'}(:);
  hybm = nc{'hybm'}(:);
  hyam = nc{'hyam'}(:);
  levs = nc{'lev'}(:);
  P0   = nc{'P0'}(:);
nc = close(nc);

%  Get NMC data:

cd /home/disk/tao/data/nmc.reanalysis/monthly

filin = 'uwnd.mon.mean.nc';
nc = netcdf(filin, 'nowrite');
  nmclev = nc{'level'}(:);
  nmclat = nc{'lat'}(:);
  nmclon = nc{'lon'}(:);
nc = close(nc);

uc_nmc = atlev(uc, nmclev, psc, hyam, hybm, P0);
vc_nmc = atlev(vc, nmclev, psc, hyam, hybm, P0);
uw_nmc = atlev(uw, nmclev, psw, hyam, hybm, P0);
vw_nmc = atlev(vw, nmclev, psw, hyam, hybm, P0);

cd /home/disk/tao/dvimont/matlab/CCM/GR

lev = 1000;
filin = 'uwnd.mon.mean.nc';
var_nam = 'uwnd';
[u1000gr, u1000cl] = reg_gr(filin, var_nam, lev);
filin = 'vwnd.mon.mean.nc';
var_nam = 'vwnd';
[v1000gr, v1000cl] = reg_gr(filin, var_nam, lev);

get_global

FRAME = [0 360 -90 90];

nthin = 2;
cthin = 2;

lev = 1000;
top1 = thin(u1000gr,nthin);
top2 = thin(v1000gr,nthin);
lind = find(nmclev == lev);
bot1 = thin(squeeze(mean(uw_nmc(:,lind,:,:) - uc_nmc(:,lind,:,:))), cthin)/2;
bot2 = thin(squeeze(mean(vw_nmc(:,lind,:,:) - vc_nmc(:,lind,:,:))), cthin)/2;
%bot1 = thin(squeeze(mean(sqrt(txw)-sqrt(txc))),cthin)/2;
%bot2 = thin(squeeze(mean(sqrt(tyw)-sqrt(tyc))),cthin)/2;

FRAME = [0 360 -40 40];
figure(1)
orient landscape
sp(1)
XAX = thin(nmclon,nthin);
YAX = thin(nmclat,nthin);
mquiv(top1, top2, 1, 'giso', [0 180])
yticks = 0; xticks = 0;
manual_ticks('x',xticks,['']); manual_ticks('y',yticks,['EQ']);
title(['NMC:  ' num2str(lev) 'mb WINDS Regressed on GR']);
%figure(2)
orient landscape
sp(2)
XAX = thin(lon,cthin);
YAX = thin(lat,cthin);
mquiv(bot1, bot2, 1, 'giso', [0 180]);
manual_ticks('x',xticks,['']); manual_ticks('y',yticks,['EQ']);
title(['GR Run:  ' num2str(lev) 'mb WINDS (WARM - COLD)/2']);

cd /home/disk/tao/dvimont/matlab/CCM/GR/GR_Plots