Files
Earthquake/analysis3.m
2021-06-12 00:26:34 +03:00

119 lines
2.7 KiB
Matlab
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

%% By L_DelOff
% собираю данные по землетрясению 11 марта 2011, Япония
% получаю среднесуточные значения концентрации H-He O2 E и электронную
% температуру в области эпицентра
%% Поехали
M=9.1;
param.k=1.2
param.type_sensor='ssies';
for i=15:18
for j=[10^(0.43*M) 1000]
param.sattelite_range=i;%15:18; % Выбор с какого спутника требуются данные
param.year_range=2011; %
param.month_range=3; %
param.day_range=1:16;
param.M=M; % Япония, 11 марта 2011
param.R_quake=j; % радиус действия относительно магнитуды,км (еще тыщу ставил)
% расположение эпицентра
param.fiA=38.297; % широта
param.LA=142.373; % долгота
param.day_x=11;
param=analysis(param);
grafik(param)
end
end
function grafik(param)
win1=figure;
win1.Name=['Япония, 11.03.2011, [38.322; 142.369]',' M=',num2str(param.M),...
' R=',num2str(fix(param.R_quake)), 'км Sat: F-',num2str(param.sattelite_range)];
win1.Units='normalized';
win1.OuterPosition = [0 0 1 1];
t1=uicontrol(win1,'Style','text');
t1.Units='Normalized';
t1.Position = [0.1 0.98 0.8 0.02];
t1.String = win1.Name;
t1.FontSize = 12;
t1.BackgroundColor=[1 1 1];
ax1=subplot(2,2,1,'Parent',win1);
y=[];
for i=1:length(param.report)
y(i)=param.report(i).RPA_HHeden;
end
explot(ax1,y,[1 16],param)
title('H-He');
ax2=subplot(2,2,2,'Parent',win1);
y=[];
for i=1:length(param.report)
y(i)=param.report(i).EP_Etemp;
end
explot(ax2,y,[1 16],param)
title('E_{temp}');
ax3=subplot(2,2,3,'Parent',win1);
y=[];
for i=1:length(param.report)
y(i)=param.report(i).RPA_O2den;
end
explot(ax3,y,[1 16],param)
title('O_2');
ax4=subplot(2,2,4,'Parent',win1);
y=[];
for i=1:length(param.report)
y(i)=param.report(i).EP_Eden;
end
explot(ax4,y,[1 16],param)
title('E');
saveas(win1,['Jap_11032011_R',num2str(fix(param.R_quake)),'F-',num2str(param.sattelite_range)],'bmp');
end
function explot(ax,y,setXLim,param)
plot(ax,y,'Color','k','Marker','o');
xticks(1:length(y))
xticklabels({param.report.date})
xtickangle(45)
grid on
hold on
Q1=quantile(y,0.25);
Q2=quantile(y,0.5);
Q3=quantile(y,0.75);
L1=Q2-param.k*(Q3-Q1);
L2=Q2+param.k*(Q3-Q1);
XLim=ax.XLim;
plot(ax,XLim,[L1 L1],'Color','b','LineStyle','--');
plot(ax,XLim,[L2 L2],'Color','b','LineStyle','--');
plot(ax,XLim,[Q2 Q2],'Color','m','LineStyle','--');
YLim=ax.YLim;
plot(ax,[param.day_x param.day_x],YLim,'Color','r');
ax.XLim=setXLim;
end