| 1 |
gforget |
1.1 |
|
| 2 |
gforget |
1.5 |
choiceGrid='v4'; |
| 3 |
|
|
|
| 4 |
|
|
%need to replace the missing v3 files... |
| 5 |
|
|
% |
| 6 |
gforget |
1.3 |
%choose grid for test |
| 7 |
gforget |
1.5 |
% fprintf('\n Please set the demo grid : \n'); |
| 8 |
|
|
% fprintf(' ''llc'': lat-lon-cap grid (5 faces). \n'); |
| 9 |
|
|
% fprintf(' ''ll'' : simple lat-lon grid (1 face). \n'); |
| 10 |
|
|
% choiceGrid=input(' and type return. ''llc'' is the default.\n'); |
| 11 |
|
|
% if isempty(choiceGrid); choiceGrid='llc'; end; |
| 12 |
|
|
% if strcmp(choiceGrid,'llc'); choiceGrid='v4'; |
| 13 |
|
|
% elseif strcmp(choiceGrid,'ll'); choiceGrid='v3'; |
| 14 |
|
|
% else; error('wrong grid choice'); |
| 15 |
|
|
% end; |
| 16 |
gforget |
1.3 |
|
| 17 |
|
|
%choose verbise level |
| 18 |
|
|
fprintf('\n Please set the amount of explanatory text display :\n'); |
| 19 |
|
|
fprintf(' 0: none.\n'); |
| 20 |
|
|
fprintf(' 1: comments.\n'); |
| 21 |
|
|
fprintf(' 2: comments preceeded with calling sequence.\n'); |
| 22 |
|
|
fprintf(' 3: same as 2, but preceeded with pause.\n'); |
| 23 |
|
|
verbose=input(' and/or type return. 0 is the default. \n'); |
| 24 |
|
|
if isempty(verbose); verbose=0; end; |
| 25 |
|
|
|
| 26 |
gforget |
1.2 |
%initialize environment variables and mygrid |
| 27 |
gforget |
1.6 |
addpath gcmfaces; |
| 28 |
gforget |
1.5 |
gcmfaces_global; |
| 29 |
gforget |
1.3 |
myenv.verbose=verbose; |
| 30 |
|
|
if myenv.verbose>0; |
| 31 |
|
|
gcmfaces_msg('* set path and environment variables (myenv) by calling gcmfaces_global'); |
| 32 |
|
|
end; |
| 33 |
gforget |
1.1 |
|
| 34 |
gforget |
1.6 |
if ~isempty(which('MITprof_global')); |
| 35 |
|
|
MITprof_global; |
| 36 |
|
|
if myenv.verbose>0; |
| 37 |
|
|
gcmfaces_msg('* set MITprof path by calling MITprof_global'); |
| 38 |
|
|
end; |
| 39 |
|
|
end; |
| 40 |
|
|
|
| 41 |
gforget |
1.5 |
fprintf('\n\n'); |
| 42 |
|
|
gcmfaces_msg('/////////////////////////////////////////'); |
| 43 |
|
|
gcmfaces_msg('demo of transport computations','// PART 1 :'); |
| 44 |
|
|
gcmfaces_msg('please hit return','// >> '); |
| 45 |
|
|
gcmfaces_msg('/////////////////////////////////////////'); |
| 46 |
|
|
fprintf('\n\n'); |
| 47 |
|
|
pause; |
| 48 |
|
|
diags=example_transports(choiceGrid); |
| 49 |
|
|
if ~isempty(diags); |
| 50 |
|
|
example_transports_disp(diags); |
| 51 |
|
|
end; |
| 52 |
|
|
|
| 53 |
|
|
fprintf('\n\n'); |
| 54 |
|
|
gcmfaces_msg('/////////////////////////////////////'); |
| 55 |
|
|
gcmfaces_msg('demo of plotting routines','// PART 2 :'); |
| 56 |
|
|
gcmfaces_msg('please hit return','// >> '); |
| 57 |
|
|
gcmfaces_msg('/////////////////////////////////////'); |
| 58 |
|
|
fprintf('\n\n'); |
| 59 |
|
|
pause; |
| 60 |
|
|
plot_one_field(choiceGrid,0);%%incl. call to m_map_gcmfaces; |
| 61 |
gforget |
1.1 |
|
| 62 |
gforget |
1.5 |
fprintf('\n\n'); |
| 63 |
|
|
gcmfaces_msg('///////////////////////////////////////////'); |
| 64 |
|
|
gcmfaces_msg('demo of gridding v interpolating','// PART 3 :'); |
| 65 |
|
|
gcmfaces_msg('please hit return','// >> '); |
| 66 |
|
|
gcmfaces_msg('///////////////////////////////////////////'); |
| 67 |
|
|
fprintf('\n\n'); |
| 68 |
|
|
pause; |
| 69 |
gforget |
1.1 |
example_bin_average(choiceGrid,1);%incl. call to example_smooth.m; |
| 70 |
|
|
example_griddata(choiceGrid); |
| 71 |
|
|
example_interp(choiceGrid); |
| 72 |
gforget |
1.4 |
example_faces2latlon2faces(choiceGrid); |
| 73 |
gforget |
1.1 |
|
| 74 |
gforget |
1.6 |
fprintf('\n\n'); |
| 75 |
|
|
gcmfaces_msg('/////////////////////////////////////////'); |
| 76 |
|
|
gcmfaces_msg('demo of budget computations','// PART 4 :'); |
| 77 |
|
|
gcmfaces_msg('please hit return','// >> '); |
| 78 |
|
|
gcmfaces_msg('/////////////////////////////////////////'); |
| 79 |
|
|
fprintf('\n\n'); |
| 80 |
|
|
pause; |
| 81 |
|
|
example_budget(choiceGrid); |
| 82 |
gforget |
1.1 |
|