1 |
dimitri |
1.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 |
dimitri |
1.3 |
(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 |
dimitri |
1.1 |
|
15 |
|
|
|
16 |
dimitri |
1.2 |
=============================================== |
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 |
dimitri |
1.10 |
cvs co -P MITgcm |
26 |
dimitri |
1.2 |
|
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 |
dimitri |
1.3 |
3 ===> compile and link |
33 |
dimitri |
1.2 |
|
34 |
|
|
cd bin |
35 |
|
|
cp ../verification/global_with_exf/code/* . |
36 |
|
|
cp ../ocean_inversion_project/code/* . |
37 |
dimitri |
1.12 |
rm ptracers_*.F PTRACERS_OPTIONS.h |
38 |
dimitri |
1.11 |
../tools/genmake2 |
39 |
|
|
(on orion: ../tools/genmake2 -of linux_ia64_efc+mpi) |
40 |
dimitri |
1.2 |
make depend |
41 |
|
|
make |
42 |
|
|
|
43 |
|
|
4 ===> execute |
44 |
|
|
|
45 |
|
|
cd ../exe |
46 |
dimitri |
1.3 |
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 |
dimitri |
1.2 |
cp ../ocean_inversion_project/input/* . |
51 |
dimitri |
1.3 |
cp data.test data |
52 |
|
|
cp data.ptracers.test data.ptracers |
53 |
dimitri |
1.4 |
mitgcmuv > output.txt |
54 |
dimitri |
1.2 |
|
55 |
dimitri |
1.5 |
5 ===> check that PTRACER output and salinity output are identical. |
56 |
dimitri |
1.2 |
|
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 |
dimitri |
1.3 |
========================================================== |
62 |
|
|
Instructions for carrying out a 3000-year quasi-stationary |
63 |
|
|
integration using the global_ocean.90x40x15 configuration. |
64 |
|
|
========================================================== |
65 |
|
|
|
66 |
|
|
cd MITgcm/exe |
67 |
|
|
rm * |
68 |
|
|
cd ../bin |
69 |
|
|
rm * |
70 |
dimitri |
1.1 |
cp ../verification/global_with_exf/code/* . |
71 |
dimitri |
1.3 |
cp ../ocean_inversion_project/code/.genmakerc . |
72 |
|
|
cp ../ocean_inversion_project/code/* . |
73 |
dimitri |
1.12 |
rm PTRACERS_OPTIONS.h |
74 |
dimitri |
1.11 |
../tools/genmake2 |
75 |
|
|
(on orion: ../tools/genmake2 -of linux_ia64_efc+mpi) |
76 |
dimitri |
1.1 |
make depend |
77 |
|
|
make |
78 |
|
|
cd ../exe |
79 |
dimitri |
1.3 |
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 |
dimitri |
1.1 |
|
89 |
dimitri |
1.8 |
========================================================== |
90 |
|
|
MPI instructions for carrying out a 3000-year quasi-stationary |
91 |
|
|
integration using the global_ocean.90x40x15 configuration. |
92 |
|
|
========================================================== |
93 |
|
|
|
94 |
|
|
cd MITgcm/exe |
95 |
|
|
rm * |
96 |
|
|
cd ../bin |
97 |
|
|
rm * |
98 |
|
|
cp ../verification/global_with_exf/code/* . |
99 |
|
|
cp ../ocean_inversion_project/code/.genmakerc . |
100 |
|
|
cp ../ocean_inversion_project/code/* . |
101 |
dimitri |
1.12 |
rm PTRACERS_OPTIONS.h |
102 |
dimitri |
1.8 |
cp CPP_EEOPTIONS.h_mpi CPP_EEOPTIONS.h |
103 |
|
|
cp SIZE.h_mpi SIZE.h |
104 |
dimitri |
1.11 |
../tools/genmake2 |
105 |
|
|
(on orion: ../tools/genmake2 -of linux_ia64_efc+mpi) |
106 |
dimitri |
1.8 |
make depend |
107 |
|
|
make |
108 |
|
|
cd ../exe |
109 |
|
|
cp ../verification/global_with_exf/input/eedata . |
110 |
|
|
cp ../verification/global_with_exf/input/data.* . |
111 |
|
|
cp ../verification/global_with_exf/input/POLY3.COEFFS . |
112 |
|
|
ln -sf ../verification/global_with_exf/input/*.bin . |
113 |
|
|
cp ../ocean_inversion_project/input/* . |
114 |
|
|
ln -sf ../ocean_inversion_project/region_mask/30reg_regionmask.bin . |
115 |
|
|
ln -sf ../ocean_inversion_project/takahashi/taka02_montlhy.bin . |
116 |
dimitri |
1.9 |
mpirun -np 36 dplace -s1 -c3-38 mitgcmuv < /dev/null > & ! errlog & |
117 |
dimitri |
1.12 |
|
118 |
|
|
|
119 |
|
|
========================================================== |
120 |
|
|
Instructions for carrying out time-dependent, 1765-2005, |
121 |
|
|
anthropogenic carbon perturbation tracer experiments using |
122 |
|
|
the global_ocean.90x40x15 configuration. |
123 |
|
|
========================================================== |
124 |
|
|
|
125 |
|
|
cd MITgcm/exe |
126 |
|
|
rm * |
127 |
|
|
cd ../bin |
128 |
|
|
rm * |
129 |
|
|
cp ../verification/global_with_exf/code/* . |
130 |
|
|
cp ../ocean_inversion_project/code/.genmakerc . |
131 |
|
|
cp ../ocean_inversion_project/code/* . |
132 |
|
|
../tools/genmake2 |
133 |
|
|
(on orion: ../tools/genmake2 -of linux_ia64_efc+mpi) |
134 |
|
|
make depend |
135 |
|
|
make |
136 |
|
|
cd ../exe |
137 |
|
|
cp ../verification/global_with_exf/input/eedata . |
138 |
|
|
cp ../verification/global_with_exf/input/data.* . |
139 |
|
|
cp ../verification/global_with_exf/input/POLY3.COEFFS . |
140 |
|
|
ln -sf ../verification/global_with_exf/input/*.bin . |
141 |
|
|
cp ../ocean_inversion_project/input/* . |
142 |
|
|
cp data.1765-2005 data |
143 |
|
|
ln -sf ../ocean_inversion_project/region_mask/30reg_regionmask.bin . |
144 |
|
|
ln -sf ../ocean_inversion_project/takahashi/taka02_montlhy.bin . |
145 |
|
|
ln -sf ../ocean_inversion_project/atm_co2/splco2_cis92a.dat . |
146 |
|
|
mitgcmuv > output .txt & |
147 |
dimitri |
1.8 |
|
148 |
|
|
|
149 |
dimitri |
1.3 |
====================================================== |
150 |
dimitri |
1.1 |
|
151 |
dimitri |
1.3 |
% some matlab code for looking at fort.10 debug files |
152 |
|
|
load fort.10 |
153 |
|
|
tak=zeros(90,40,12); |
154 |
|
|
for n=1:length(fort) |
155 |
|
|
m=fort(n,1); i=fort(n,2); j=fort(n,3); |
156 |
|
|
if i>0&i<91&j>0&j<41, tak(i,j,m)=fort(n,4); end |
157 |
|
|
end |
158 |
|
|
lon=2:4:360; lat=-78:4:78; |
159 |
|
|
clf, contourf(lon,lat,mean(tak(:,:,1),3)',-10:10) |
160 |
|
|
caxis([-6 6]), colorbar, plotland |
161 |
|
|
|
162 |
|
|
% some matlab code for looking at PTRACER output files |
163 |
dimitri |
1.4 |
salt=readbin('S.0000000020.001.001.data',[90 40 15],1); |
164 |
dimitri |
1.3 |
tracer=zeros(90,40,15,30); |
165 |
|
|
for i=1:30 |
166 |
|
|
fn=['PTRACER' myint2str(i) '.0000000020.001.001.data']; |
167 |
|
|
tracer(:,:,:,i)=readbin(fn,[90 40 15],1); |
168 |
|
|
clf, mypcolor(tracer(:,:,1,i)'); pause(1) |
169 |
|
|
end |
170 |
|
|
tmp=sum(tracer,4); clf, mypcolor(tmp(:,:,1)') |
171 |
dimitri |
1.4 |
mypcolor( |
172 |
|
|
|
173 |
dimitri |
1.3 |
|
174 |
|
|
% some matlab code for checking that one year's worth of |
175 |
|
|
% tracer uptake is approximately 1e18 mols. |
176 |
|
|
lon=2:4:360; lat=-78:4:78; |
177 |
|
|
thk=[50 70 100 140 190 240 290 340 390 440 490 540 590 640 690]; |
178 |
dimitri |
1.7 |
mask=readbin('hFacC.001.001.data',[90 40 15],1); |
179 |
dimitri |
1.3 |
tracer=zeros(90,40,15,30); sumtracer=zeros(30,1); |
180 |
|
|
for i=1:30, mydisp(i) |
181 |
dimitri |
1.7 |
fn=['PTRACER' myint2str(i) '.0000001800.001.001.data']; |
182 |
dimitri |
1.3 |
tracer(:,:,:,i)=readbin(fn,[90 40 15],1); |
183 |
|
|
for j=1:length(lat) |
184 |
|
|
for k=1:length(thk) |
185 |
dimitri |
1.7 |
sumtracer(i) = sumtracer(i) + sum(tracer(:,j,k,i).*mask(:,j,k)) * ... |
186 |
dimitri |
1.3 |
thk(k) * (4*1.113195e+05)^2 * cos(pi*lat(j)/180); |
187 |
|
|
end |
188 |
dimitri |
1.1 |
end |
189 |
dimitri |
1.3 |
end |
190 |
dimitri |
1.4 |
plot(1:30,0*sumtracer,1:30,sumtracer) |