source: trunk/src/mode_sahelien/reconstitution.m @ 13

Last change on this file since 13 was 10, checked in by pinsard, 16 years ago

first commit with original work of Sebastien Gervois

File size: 3.1 KB
Line 
1clear; close all;
2
3load eof_rossby_jjas.mat
4olr_centre=olr_centre';
5PC1=olr_centre*C;
6
7cosa=zeros(3,2684,425);
8for a=1:3; % boucle sur les VP
9      for b=1:2684 % boucle sur le temps
10          for c=1:425 % boucle sur l espace
11             cosa(a,b,c)=PC1(b,426-a)*C(c,426-a);
12          end;
13      end;
14end;
15
16cosi3(:,:)=sum(cosa); cosi3=reshape(cosi3,2684,17,25);
17
18cosabis=cosa(1:2,:,:);
19cosi2(:,:)=sum(cosabis); clear cosabis;
20cosi2=reshape(cosi2,2684,17,25);
21
22cosa1(:,:)=cosa(1,:,:); clear cosa;
23cosi1=reshape(cosa1,2684,17,25); clear cosa1;
24
25
26figure(1); orient('landscape')
27figure(2); orient('landscape')
28figure(3); orient('landscape')
29
30% On selectionne la demaine geographique
31
32taille=(12-7+1)*(17-9+1);
33cosa1=cosi1(:,7:12,9:17); clear cosi1;
34cosa1=reshape(cosa1,2684,taille);
35cosa1=cosa1';
36cosa1=mean(cosa1);
37cosa1=cosa1';
38cosa1=reshape(cosa1,122,22);
39
40cosa2=cosi2(:,7:12,9:17); clear cosi2;
41cosa2=reshape(cosa2,2684,taille);
42cosa2=cosa2';
43cosa2=mean(cosa2);
44cosa2=cosa2';
45save mode_rossby_jjas.txt cosa2 -ascii;
46
47cosa2=reshape(cosa2,122,22);
48
49cosa3=cosi3(:,7:12,9:17); clear cosi3;
50cosa3=reshape(cosa3,2684,taille);
51cosa3=cosa3';
52cosa3=mean(cosa3);
53cosa3=cosa3';
54cosa3=reshape(cosa3,122,22);
55
56
57
58% On selectionne la demaine geographique
59olr_centre=reshape(olr_centre,2684,17,25);
60cosa4=olr_centre(:,7:12,9:17); clear olr_centre;
61cosa4=reshape(cosa4,2684,taille); clear taille;
62cosa4=cosa4';
63cosa4=mean(cosa4);
64cosa4=cosa4';
65cosa4=reshape(cosa4,122,22);
66
67for a=1:22;
68     if a<12;
69        figure(1); subplot(4,3,a);
70     else
71        figure(2); subplot(4,3,a-11);
72     end
73     y1=cosa1(:,a);
74     y2=cosa2(:,a);
75     y3=cosa3(:,a);
76     y4=cosa4(:,a);
77     x=[1:122]';
78     plot(x,y1,'r');
79     hold on;
80     plot(x,y2);
81     plot(x,y3,'g');
82     plot(x,y4,'k');
83     y5=zeros(122,1);
84     plot(x,y5,'k:');
85     
86     title(a+1978,'Fontsize',8);
87     if a==2;
88         text(0,65,'OLR 5 -17.5N et 10W - 10E');
89     elseif a==13;
90         text(0,65,'OLR 5 - 17.5N et 10W - 10E');
91     end
92     set(gca,'tickDir','out');
93     if a==11;
94        aa=legend('OLR VP1','OLR VP1-2','OLR VP1-3','OLR NOAA');
95        set(aa,'fontsize',8,'Position',[0.6800 0.1039 0.1270 0.1642])
96        legend boxoff;
97     elseif a==22;
98        clear aa;
99        aa=legend('OLR VP1','OLR VP1-2','OLR VP1-3','OLR NOAA');
100        set(aa,'fontsize',8,'Position',[0.6800 0.1039 0.1270 0.1642])
101        legend boxoff;
102     elseif a==22;
103        clear aa;
104        aa=legend('OLR VP1','OLR VP1-2','OLR VP1-3','OLR NOAA');
105        set(aa,'fontsize',8,'Position',[0.6800 0.1039 0.1270 0.1642])
106        legend boxoff;
107     end;
108     axis([1 122 -40 40]);
109     set (gca,'YTick',[-40:20:40],'YTickLabel',[-40:20:40],'fontname','Arial','fontsize',6);
110   set (gca,'XTick',[10:10:90],'XTickLabel',[10:10:90],'fontname','Arial','fontsize',6);
111
112end;
113
114
115
116figure(1);
117print -depsc2 reconstitution_OLR_JJAS_part1.eps;
118figure(2);
119print -depsc2 reconstitution_OLR_JJAS_part2.eps;
120figure(3);
121print -depsc2 reconstitution_OLR_JJAS_part3.eps;
Note: See TracBrowser for help on using the repository browser.