more analysis
This commit is contained in:
66
Matlab_post_analysis/post_analysis.m
Normal file
66
Matlab_post_analysis/post_analysis.m
Normal file
@@ -0,0 +1,66 @@
|
||||
close all;
|
||||
events= readtable("001rec_SI.csv");
|
||||
result = readmatrix("001rec_ADC_data.csv");
|
||||
%result = result(14430:end, : );
|
||||
result(:,14) = result(:,14)./2;
|
||||
time = result(:,1)./1000;
|
||||
|
||||
temp = 0.000111 .* result(:,4:9) + 2.31991;
|
||||
|
||||
pressure = result(:,10:17).*(0.000015)-6.565;
|
||||
|
||||
load_cell = result(:,2:3);
|
||||
weight = -1.166759307845543e-04 .* 0.5.*(load_cell(:,1) + load_cell(:,2)) + 4.971416323340051e+02;
|
||||
|
||||
figure()
|
||||
scatter(time,weight,10)
|
||||
title("load cell in Kg")
|
||||
xlabel("Time in s")
|
||||
ylabel("KG")
|
||||
xlim([878.207 920.111+5.000])
|
||||
|
||||
|
||||
pressureNames = { ...
|
||||
'LOX tank pressure', ...
|
||||
'Ethanol tank pressure', ...
|
||||
'Ethanol pressure in injection plate', ...
|
||||
'Chamber pressure', ...
|
||||
'Ethanol pressure at inlet', ...
|
||||
'Pressure channel 6', ...
|
||||
'Pressure channel 7'};
|
||||
|
||||
for x = 1:7
|
||||
figure()
|
||||
hold on;
|
||||
|
||||
% Left axis → weight/thrust
|
||||
yyaxis left
|
||||
scatter(time, weight, 'DisplayName', 'Thrust');
|
||||
ylabel("Thrust / Weight")
|
||||
|
||||
% Right axis → pressure
|
||||
yyaxis right
|
||||
scatter(time, pressure(:,x), 10, 'DisplayName', 'Pressure');
|
||||
ylabel("Pressure")
|
||||
|
||||
% Title using your descriptive spreadsheet names
|
||||
title(pressureNames{x})
|
||||
|
||||
xlabel("Time in s")
|
||||
legend()
|
||||
xlim([878.207 920.111 + 5.000])
|
||||
end
|
||||
|
||||
%{
|
||||
for x = 1:6
|
||||
figure()
|
||||
scatter(time,temp(:,x),10)
|
||||
title(sprintf("temperature channel %d",x))
|
||||
xlabel("Time in s")
|
||||
ylabel("Temprature in C")
|
||||
xlim([878.207 920.111+5.000])
|
||||
end
|
||||
|
||||
|
||||
%}
|
||||
|
||||
Reference in New Issue
Block a user