-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathplotData.m
More file actions
82 lines (74 loc) · 2.24 KB
/
Copy pathplotData.m
File metadata and controls
82 lines (74 loc) · 2.24 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
%% unzip
if ~isfile('ExperimentalData_01.csv')
unzip('ExperimentalData_01.zip');
end
if ~isfile('ExperimentalData_02.csv')
unzip('ExperimentalData_02.zip');
end
if ~isfile('ExperimentalData_03.csv')
unzip('ExperimentalData_03.zip');
end
if ~isfile('ExperimentalData_04.csv')
unzip('ExperimentalData_04.zip');
end
if ~isfile('ExperimentalData_05.csv')
unzip('ExperimentalData_05.zip');
end
if ~isfile('ExperimentalData_06.csv')
unzip('ExperimentalData_06.zip');
end
%% load data
expDataSet_01 = readtable('ExperimentalData_01.csv');
expDataSet_02 = readtable('ExperimentalData_02.csv');
expDataSet_03 = readtable('ExperimentalData_03.csv');
expDataSet_04 = readtable('ExperimentalData_04.csv');
expDataSet_05 = readtable('ExperimentalData_05.csv');
expDataSet_06 = readtable('ExperimentalData_06.csv');
expDataSet = [expDataSet_01; expDataSet_02; expDataSet_03; expDataSet_04; expDataSet_05; expDataSet_06];
clear expDataSet_01 expDataSet_02 expDataSet_03 expDataSet_04 expDataSet_05 expDataSet_06
% -- rated values of rotational speed and power
omega_rated = 431; % / rpm
P_rated = 3e6; % / W
%% plot
figure
subplot(5,1,1)
hold on
plot(expDataSet.TimeStamps, expDataSet.sensor_windSpeed);
plot(expDataSet.TimeStamps, expDataSet.EKF_state_v_windeff);
hold off
grid on
xlabel('time')
ylabel('v / m/s')
legend('v_h', 'v_{w_eff}')
subplot(5,1,2)
hold on
plot(expDataSet.TimeStamps, expDataSet.sensor_omega_g);
plot([expDataSet.TimeStamps(1), expDataSet.TimeStamps(end)], [omega_rated, omega_rated]);
hold off
grid on
xlabel('time')
ylabel('omega_g / rpm')
legend('R-MPC', 'rated')
subplot(5,1,3)
hold on
plot(expDataSet.TimeStamps, expDataSet.sensor_P_g*1e3);
plot([expDataSet.TimeStamps(1), expDataSet.TimeStamps(end)], [P_rated, P_rated]);
hold off
grid on
xlabel('time')
ylabel('P_g / W')
subplot(5,1,4)
hold on
plot(expDataSet.TimeStamps, expDataSet.sensor_theta_1);
plot(expDataSet.TimeStamps, expDataSet.sensor_theta_2);
plot(expDataSet.TimeStamps, expDataSet.sensor_theta_3);
hold off
grid on
xlabel('time')
ylabel('theta / deg')
legend('theta_1', 'theta_2', 'theta_3')
subplot(5,1,5)
plot(expDataSet.TimeStamps, expDataSet.sensor_T_g);
grid on
xlabel('time')
ylabel('T_g / N m')