1 | % 1 floater 2 pts |
---|
2 | |
---|
3 | close all |
---|
4 | |
---|
5 | figure(1) |
---|
6 | |
---|
7 | ls; |
---|
8 | load obs_float_test.dat; |
---|
9 | whos; |
---|
10 | obs_float_test (1:4,:) |
---|
11 | x=obs_float_test (1:2:12,4) |
---|
12 | y=obs_float_test (2:2:12,4) |
---|
13 | x=x+1 |
---|
14 | y=y+1 |
---|
15 | plot(x(1),y(1),'+') |
---|
16 | hold on; |
---|
17 | plot(x(6),y(6),'>') |
---|
18 | hold on; |
---|
19 | plot(x(1:6),y(1:6),'+'); |
---|
20 | hold on; |
---|
21 | plot(x(1:6),y(1:6),'-r') |
---|
22 | hold on; |
---|
23 | |
---|
24 | |
---|
25 | x3=obs_float_test (13:2:24,4) |
---|
26 | y3=obs_float_test (14:2:24,4) |
---|
27 | x3=x3+1 |
---|
28 | y3=y3+1 |
---|
29 | plot(x3(1),y3(1),'+') |
---|
30 | hold on; |
---|
31 | plot(x3(6),y3(6),'>') |
---|
32 | hold on; |
---|
33 | plot(x3(1:6),y3(1:6),'+'); |
---|
34 | hold on; |
---|
35 | plot(x3(1:6),y3(1:6),'-r') |
---|
36 | hold on; |
---|
37 | |
---|
38 | x5=obs_float_test (25:2:36,4) |
---|
39 | y5=obs_float_test (26:2:36,4) |
---|
40 | x5=x5+1 |
---|
41 | y5=y5+1 |
---|
42 | plot(x5(1),y5(1),'+') |
---|
43 | hold on; |
---|
44 | plot(x5(6),y5(6),'>') |
---|
45 | hold on; |
---|
46 | plot(x5(1:6),y5(1:6),'+'); |
---|
47 | hold on; |
---|
48 | plot(x5(1:6),y5(1:6),'-r') |
---|
49 | hold on; |
---|
50 | |
---|
51 | x7=obs_float_test (37:2:48,4) |
---|
52 | y7=obs_float_test (38:2:48,4) |
---|
53 | x7=x7+1 |
---|
54 | y7=y7+1 |
---|
55 | plot(x7(1),y7(1),'+') |
---|
56 | hold on; |
---|
57 | plot(x7(6),y7(6),'>') |
---|
58 | hold on; |
---|
59 | plot(x7(1:6),y7(1:6),'+'); |
---|
60 | hold on; |
---|
61 | plot(x7(1:6),y7(1:6),'-r') |
---|
62 | hold on; |
---|
63 | |
---|
64 | |
---|
65 | |
---|
66 | load rfloat_total.dat |
---|
67 | g=1; |
---|
68 | j=1 |
---|
69 | while g<20 |
---|
70 | |
---|
71 | x2=rfloat_total(g:g+4,4) |
---|
72 | y2=rfloat_total(g:g+4,3) |
---|
73 | x2=x2+1 |
---|
74 | y2=y2+1 |
---|
75 | x2(1)=obs_float_test(j,4); |
---|
76 | y2(1)=obs_float_test(j+1,4); |
---|
77 | x2(1)=x2(1)+1; |
---|
78 | y2(1)=y2(1)+1; |
---|
79 | [k,h]=size(x2); |
---|
80 | plot(x2(1),y2(1),'+') |
---|
81 | hold on; |
---|
82 | plot(x2(k-1),y2(k-1),'>') |
---|
83 | hold on; |
---|
84 | plot(x2(2:k-1),y2(2:k-1),'+') |
---|
85 | hold on; |
---|
86 | plot(x2(1:k-1),y2(1:k-1),'-g') |
---|
87 | hold on; |
---|
88 | g=g+4; |
---|
89 | j=j+2; |
---|
90 | end |
---|
91 | |
---|
92 | |
---|
93 | j=13; |
---|
94 | g=22; |
---|
95 | while g<40 |
---|
96 | |
---|
97 | x2=rfloat_total(g:g+4,4) |
---|
98 | y2=rfloat_total(g:g+4,3) |
---|
99 | x2=x2+1 |
---|
100 | y2=y2+1 |
---|
101 | x2(1)=obs_float_test(j,4); |
---|
102 | y2(1)=obs_float_test(j+1,4); |
---|
103 | x2(1)=x2(1)+1; |
---|
104 | y2(1)=y2(1)+1; |
---|
105 | [k,h]=size(x2); |
---|
106 | plot(x2(1),y2(1),'+') |
---|
107 | hold on; |
---|
108 | plot(x2(k-1),y2(k-1),'>') |
---|
109 | hold on; |
---|
110 | plot(x2(2:k-1),y2(2:k-1),'+') |
---|
111 | hold on; |
---|
112 | plot(x2(1:k-1),y2(1:k-1),'-g') |
---|
113 | hold on; |
---|
114 | g=g+4; |
---|
115 | j=j+2; |
---|
116 | end |
---|
117 | |
---|
118 | j=25; |
---|
119 | |
---|
120 | g=43; |
---|
121 | while g<60 |
---|
122 | |
---|
123 | x2=rfloat_total(g:g+4,4) |
---|
124 | y2=rfloat_total(g:g+4,3) |
---|
125 | x2=x2+1 |
---|
126 | y2=y2+1 |
---|
127 | x2(1)=obs_float_test(j,4); |
---|
128 | y2(1)=obs_float_test(j+1,4); |
---|
129 | x2(1)=x2(1)+1; |
---|
130 | y2(1)=y2(1)+1; |
---|
131 | [k,h]=size(x2); |
---|
132 | plot(x2(1),y2(1),'+') |
---|
133 | hold on; |
---|
134 | plot(x2(k-1),y2(k-1),'>') |
---|
135 | hold on; |
---|
136 | plot(x2(2:k-1),y2(2:k-1),'+') |
---|
137 | hold on; |
---|
138 | plot(x2(1:k-1),y2(1:k-1),'-g') |
---|
139 | hold on; |
---|
140 | g=g+4; |
---|
141 | j=j+2; |
---|
142 | end |
---|
143 | |
---|
144 | |
---|
145 | j=37; |
---|
146 | |
---|
147 | g=64; |
---|
148 | while g<84 |
---|
149 | |
---|
150 | x2=rfloat_total(g:g+4,4) |
---|
151 | y2=rfloat_total(g:g+4,3) |
---|
152 | x2=x2+1 |
---|
153 | y2=y2+1 |
---|
154 | x2(1)=obs_float_test(j,4); |
---|
155 | y2(1)=obs_float_test(j+1,4); |
---|
156 | x2(1)=x2(1)+1; |
---|
157 | y2(1)=y2(1)+1; |
---|
158 | [k,h]=size(x2); |
---|
159 | plot(x2(1),y2(1),'+') |
---|
160 | hold on; |
---|
161 | plot(x2(k-1),y2(k-1),'>') |
---|
162 | hold on; |
---|
163 | plot(x2(2:k-1),y2(2:k-1),'+') |
---|
164 | hold on; |
---|
165 | plot(x2(1:k-1),y2(1:k-1),'-g') |
---|
166 | hold on; |
---|
167 | g=g+4; |
---|
168 | j=j+2; |
---|
169 | end |
---|
170 | |
---|
171 | load uv_total.dat; |
---|
172 | whos; |
---|
173 | X1=uv_total(1:5046,end-3); |
---|
174 | Y1=uv_total(1:5046,end-2); |
---|
175 | X1=X1+1; |
---|
176 | Y1=Y1+1; |
---|
177 | %change si pas de temps change |
---|
178 | U1=zeros(5046,1); |
---|
179 | V1=zeros(5046,1); |
---|
180 | e=1; |
---|
181 | for r=1:1:19 |
---|
182 | |
---|
183 | for count=1:5046 |
---|
184 | Unew(count)=uv_total(e,end-1); |
---|
185 | Vnew(count)=uv_total(e,end); |
---|
186 | e=e+1; |
---|
187 | end |
---|
188 | U1=U1+Unew'; |
---|
189 | V1=V1+Vnew'; |
---|
190 | |
---|
191 | |
---|
192 | end |
---|
193 | |
---|
194 | U1=U1/19; |
---|
195 | V1=V1/19; |
---|
196 | quiver(X1,Y1,U1,V1,2,'r','Autoscale','off'); |
---|
197 | |
---|
198 | |
---|
199 | load utrue.dat; |
---|
200 | |
---|
201 | utrue=roundn(utrue,-6) |
---|
202 | whos; |
---|
203 | X3=utrue(:,end-2); |
---|
204 | Y3=utrue(:,end-1); |
---|
205 | U3=utrue(:,end); |
---|
206 | load vtrue.dat |
---|
207 | vtrue=roundn(vtrue,-6) |
---|
208 | V3=vtrue(:,end); |
---|
209 | quiver(X3,Y3,U3,V3,2,'b','Autoscale','off'); |
---|
210 | |
---|
211 | load uzero.dat; |
---|
212 | |
---|
213 | |
---|
214 | whos; |
---|
215 | X2=uzero(:,end-2); |
---|
216 | Y2=uzero(:,end-1); |
---|
217 | U2=uzero(:,end); |
---|
218 | load vzero.dat |
---|
219 | |
---|
220 | V2=vzero(:,end); |
---|
221 | quiver(X2,Y2,U2,V2,2,'g','Autoscale','off'); |
---|
222 | |
---|
223 | figure(2) |
---|
224 | load vel_bck_all.dat |
---|
225 | it=find(vel_bck_all(:,1)==1); |
---|
226 | Tu=reshape(vel_bck_all(it,4),58,87); |
---|
227 | Tv=reshape(vel_bck_all(it,5),58,87); |
---|
228 | |
---|
229 | load vel_true_all.dat |
---|
230 | it=find(vel_true_all(:,1)==1); |
---|
231 | Bu=reshape(vel_true_all(it,4),58,87); |
---|
232 | Bv=reshape(vel_true_all(it,5),58,87); |
---|
233 | |
---|
234 | F=(Bu-Tu).^2+(Bv-Tv).^2 |
---|
235 | imagesc(F) |
---|
236 | |
---|
237 | |
---|
238 | figure(3) |
---|
239 | |
---|
240 | load uv_total.dat |
---|
241 | it=find(uv_total(:,1)==0); |
---|
242 | Iu0=reshape(uv_total(it,4),58,87); |
---|
243 | Iv0=reshape(uv_total(it,5),58,87); |
---|
244 | it=find(uv_total(:,1)==1); |
---|
245 | Iu1=reshape(uv_total(it,4),58,87); |
---|
246 | Iv1=reshape(uv_total(it,5),58,87); |
---|
247 | it=find(uv_total(:,1)==2); |
---|
248 | Iu2=reshape(uv_total(it,4),58,87); |
---|
249 | Iv2=reshape(uv_total(it,5),58,87); |
---|
250 | it=find(uv_total(:,1)==3); |
---|
251 | Iu3=reshape(uv_total(it,4),58,87); |
---|
252 | Iv3=reshape(uv_total(it,5),58,87); |
---|
253 | it=find(uv_total(:,1)==4); |
---|
254 | Iu4=reshape(uv_total(it,4),58,87); |
---|
255 | Iv4=reshape(uv_total(it,5),58,87); |
---|
256 | it=find(uv_total(:,1)==5); |
---|
257 | Iu5=reshape(uv_total(it,4),58,87); |
---|
258 | Iv5=reshape(uv_total(it,5),58,87); |
---|
259 | it=find(uv_total(:,1)==6); |
---|
260 | Iu6=reshape(uv_total(it,4),58,87); |
---|
261 | Iv6=reshape(uv_total(it,5),58,87); |
---|
262 | it=find(uv_total(:,1)==7); |
---|
263 | Iu7=reshape(uv_total(it,4),58,87); |
---|
264 | Iv7=reshape(uv_total(it,5),58,87); |
---|
265 | it=find(uv_total(:,1)==8); |
---|
266 | Iu8=reshape(uv_total(it,4),58,87); |
---|
267 | Iv8=reshape(uv_total(it,5),58,87); |
---|
268 | it=find(uv_total(:,1)==9); |
---|
269 | Iu9=reshape(uv_total(it,4),58,87); |
---|
270 | Iv9=reshape(uv_total(it,5),58,87); |
---|
271 | it=find(uv_total(:,1)==10); |
---|
272 | Iu10=reshape(uv_total(it,4),58,87); |
---|
273 | Iv10=reshape(uv_total(it,5),58,87); |
---|
274 | it=find(uv_total(:,1)==11); |
---|
275 | Iu11=reshape(uv_total(it,4),58,87); |
---|
276 | Iv11=reshape(uv_total(it,5),58,87); |
---|
277 | it=find(uv_total(:,1)==12); |
---|
278 | Iu12=reshape(uv_total(it,4),58,87); |
---|
279 | Iv12=reshape(uv_total(it,5),58,87); |
---|
280 | it=find(uv_total(:,1)==13); |
---|
281 | Iu13=reshape(uv_total(it,4),58,87); |
---|
282 | Iv13=reshape(uv_total(it,5),58,87); |
---|
283 | it=find(uv_total(:,1)==14); |
---|
284 | Iu14=reshape(uv_total(it,4),58,87); |
---|
285 | Iv14=reshape(uv_total(it,5),58,87); |
---|
286 | it=find(uv_total(:,1)==15); |
---|
287 | Iu15=reshape(uv_total(it,4),58,87); |
---|
288 | Iv15=reshape(uv_total(it,5),58,87); |
---|
289 | it=find(uv_total(:,1)==16); |
---|
290 | Iu16=reshape(uv_total(it,4),58,87); |
---|
291 | Iv16=reshape(uv_total(it,5),58,87); |
---|
292 | it=find(uv_total(:,1)==17); |
---|
293 | Iu17=reshape(uv_total(it,4),58,87); |
---|
294 | Iv17=reshape(uv_total(it,5),58,87); |
---|
295 | it=find(uv_total(:,1)==18) |
---|
296 | Iu18=reshape(uv_total(it,4),58,87); |
---|
297 | Iv18=reshape(uv_total(it,5),58,87); |
---|
298 | it=find(uv_total(:,1)==19) |
---|
299 | Iu19=reshape(uv_total(it,4),58,87); |
---|
300 | Iv19=reshape(uv_total(it,5),58,87); |
---|
301 | % it=find(uv_total(:,1)==20); |
---|
302 | % I20=reshape(uv_total(it,4),58,87); |
---|
303 | % it=find(uv_total(:,1)==21); |
---|
304 | % I21=reshape(uv_total(it,4),58,87); |
---|
305 | % it=find(uv_total(:,1)==22); |
---|
306 | % I22=reshape(uv_total(it,4),58,87); |
---|
307 | % it=find(uv_total(:,1)==23); |
---|
308 | % I23=reshape(uv_total(it,4),58,87); |
---|
309 | % it=find(uv_total(:,1)==24); |
---|
310 | % I24=reshape(uv_total(it,4),58,87); |
---|
311 | % it=find(uv_total(:,1)==25); |
---|
312 | % I25=reshape(uv_total(it,4),58,87); |
---|
313 | % it=find(uv_total(:,1)==26); |
---|
314 | % I26=reshape(uv_total(it,4),58,87); |
---|
315 | % it=find(uv_total(:,1)==27); |
---|
316 | % I27=reshape(uv_total(it,4),58,87); |
---|
317 | % it=find(uv_total(:,1)==28); |
---|
318 | % I28=reshape(uv_total(it,4),58,87); |
---|
319 | % it=find(uv_total(:,1)==29); |
---|
320 | % I29=reshape(uv_total(it,4),58,87); |
---|
321 | % it=find(uv_total(:,1)==30); |
---|
322 | % I30=reshape(uv_total(it,4),58,87); |
---|
323 | % it=find(uv_total(:,1)==31); |
---|
324 | % I31=reshape(uv_total(it,4),58,87); |
---|
325 | % it=find(uv_total(:,1)==32); |
---|
326 | % I32=reshape(uv_total(it,4),58,87); |
---|
327 | % it=find(uv_total(:,1)==33); |
---|
328 | % I33=reshape(uv_total(it,4),58,87); |
---|
329 | % it=find(uv_total(:,1)==34); |
---|
330 | % I34=reshape(uv_total(it,4),58,87); |
---|
331 | % it=find(uv_total(:,1)==35); |
---|
332 | % I35=reshape(uv_total(it,4),58,87); |
---|
333 | % it=find(uv_total(:,1)==36); |
---|
334 | % I36=reshape(uv_total(it,4),58,87); |
---|
335 | |
---|
336 | Cu=(Iu0+Iu1+Iu2+Iu3+Iu4+Iu5+Iu6+Iu7+Iu8+Iu9+Iu10+Iu11+Iu12+Iu13+Iu14+Iu15+Iu16+Iu17+Iu18+Iu19)/20; |
---|
337 | Cv=(Iv0+Iv1+Iv2+Iv3+Iv4+Iv5+Iv6+Iv7+Iv8+Iv9+Iv10+Iv11+Iv12+Iv13+Iv14+Iv15+Iv16+Iv17+Iv18+Iv19)/20; |
---|
338 | |
---|
339 | F1=(Tu-Cu).^2+(Tv-Cv).^2; |
---|
340 | imagesc(F1) |
---|
341 | |
---|
342 | F2=(Bu-Cu).^2+(Bv-Cv).^2; |
---|
343 | figure(4) |
---|
344 | imagesc(F2) |
---|