/[MITgcm]/MITgcm_contrib/ocean_inversion_project/README
ViewVC logotype

Contents of /MITgcm_contrib/ocean_inversion_project/README

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.6 - (show annotations) (download)
Thu Sep 25 03:01:59 2003 UTC (21 years, 9 months ago) by dimitri
Branch: MAIN
Changes since 1.5: +1 -2 lines
o Mods and bug fixes to pkg/cal, pkg/exf, etc., needed for computation
  of tracer Green's fucntions for ocean inversion project.

1 Ocean Inversion Project
2 =======================
3
4 Instructions for using pkg/ptracers to compute tracer
5 Green's functions for Gruber's ocean inversion project
6 (see quercus.igpp.ucla.edu/OceanInversion/ for details).
7
8 Preprocessed OceanInversion input files are available
9 under directories region_mask, takahashi, and
10 atm_co2 in this package. All netcdf input files
11 have been converted to binary format in order to avoid
12 having to link netcdf library with MITgcm code. See
13 respective README files in each directory for details.
14
15
16 ===============================================
17 First check that pkg/ptracers works OK by using
18 salinity initial and boundary conditions
19 ===============================================
20
21 1 ===> get MITgcm code from cvs repository
22
23 CVSROOT=:pserver:cvsanon@mitgcm.org:/u/u0/gcmpack
24 cvs login ( CVS password: cvsanon )
25 cvs co MITgcm
26
27 2 ===> put MITgcm_contrib/ocean_inversion_project in MITgcm directory
28
29 cd MITgcm
30 cvs co -d ocean_inversion_project MITgcm_contrib/ocean_inversion_project
31
32 3 ===> compile and link
33
34 cd bin
35 cp ../verification/global_with_exf/code/* .
36 cp ../ocean_inversion_project/code/.genmakerc .
37 cp ../ocean_inversion_project/code/* .
38 rm ptracers_*.F
39 ../tools/genmake
40 make depend
41 make
42
43 4 ===> execute
44
45 cd ../exe
46 cp ../verification/global_with_exf/input/eedata .
47 cp ../verification/global_with_exf/input/data.* .
48 cp ../verification/global_with_exf/input/POLY3.COEFFS .
49 ln -sf ../verification/global_with_exf/input/*.bin .
50 cp ../ocean_inversion_project/input/* .
51 cp data.test data
52 cp data.ptracers.test data.ptracers
53 mitgcmuv > output.txt
54
55 5 ===> check that PTRACER output and salinity output are identical.
56
57 diff PTRACER01.0000000020.001.001.data S.0000000020.001.001.data
58 diff PTRACER30.0000000020.001.001.data S.0000000020.001.001.data
59
60
61 ==========================================================
62 Instructions for carrying out a 3000-year quasi-stationary
63 integration using the global_ocean.90x40x15 configuration.
64 ==========================================================
65
66 1 ===> compile, link, and execute
67
68 cd MITgcm/exe
69 rm *
70 cd ../bin
71 rm *
72 cp ../verification/global_with_exf/code/* .
73 cp ../ocean_inversion_project/code/.genmakerc .
74 cp ../ocean_inversion_project/code/* .
75 ../tools/genmake
76 make depend
77 make
78 cd ../exe
79 cp ../verification/global_with_exf/input/eedata .
80 cp ../verification/global_with_exf/input/data.* .
81 cp ../verification/global_with_exf/input/POLY3.COEFFS .
82 ln -sf ../verification/global_with_exf/input/*.bin .
83 cp ../ocean_inversion_project/input/* .
84 ln -sf ../ocean_inversion_project/region_mask/30reg_regionmask.bin .
85 ln -sf ../ocean_inversion_project/takahashi/taka02_montlhy.bin .
86 mitgcmuv > output .txt &
87
88
89 ======================================================
90
91 % some matlab code for looking at fort.10 debug files
92 load fort.10
93 tak=zeros(90,40,12);
94 for n=1:length(fort)
95 m=fort(n,1); i=fort(n,2); j=fort(n,3);
96 if i>0&i<91&j>0&j<41, tak(i,j,m)=fort(n,4); end
97 end
98 lon=2:4:360; lat=-78:4:78;
99 clf, contourf(lon,lat,mean(tak(:,:,1),3)',-10:10)
100 caxis([-6 6]), colorbar, plotland
101
102 % some matlab code for looking at PTRACER output files
103 salt=readbin('S.0000000020.001.001.data',[90 40 15],1);
104 tracer=zeros(90,40,15,30);
105 for i=1:30
106 fn=['PTRACER' myint2str(i) '.0000000020.001.001.data'];
107 tracer(:,:,:,i)=readbin(fn,[90 40 15],1);
108 clf, mypcolor(tracer(:,:,1,i)'); pause(1)
109 end
110 tmp=sum(tracer,4); clf, mypcolor(tmp(:,:,1)')
111 mypcolor(
112
113
114 % some matlab code for checking that one year's worth of
115 % tracer uptake is approximately 1e18 mols.
116 lon=2:4:360; lat=-78:4:78;
117 thk=[50 70 100 140 190 240 290 340 390 440 490 540 590 640 690];
118 tracer=zeros(90,40,15,30); sumtracer1=zeros(30,1);
119 for i=1:30, mydisp(i)
120 fn=['PTRACER' myint2str(i) '.0000000180.001.001.data'];
121 tracer(:,:,:,i)=readbin(fn,[90 40 15],1);
122 for x=1:length(lon)
123 for y=1:length(lat)
124 for z=1:length(thk)
125 sumtracer1(i) = sumtracer1(i) + tracer(x,y,z,i) * ...
126 thk(z) * (4*1.113195e+05)^2 * cos(pi*lat(y)/180);
127 end
128 end
129 end
130 end
131
132 % some matlab code for checking that one year's worth of
133 % tracer uptake is approximately 1e18 mols.
134 lon=2:4:360; lat=-78:4:78;
135 thk=[50 70 100 140 190 240 290 340 390 440 490 540 590 640 690];
136 tracer=zeros(90,40,15,30); sumtracer=zeros(30,1);
137 for i=1:30, mydisp(i)
138 fn=['PTRACER' myint2str(i) '.0000003600.001.001.data'];
139 tracer(:,:,:,i)=readbin(fn,[90 40 15],1);
140 for j=1:length(lat)
141 for k=1:length(thk)
142 sumtracer(i) = sumtracer(i) + sum(tracer(:,j,k,i)) * ...
143 thk(k) * (4*1.113195e+05)^2 * cos(pi*lat(j)/180);
144 end
145 end
146 end
147 plot(1:30,0*sumtracer,1:30,sumtracer)

  ViewVC Help
Powered by ViewVC 1.1.22