-
Notifications
You must be signed in to change notification settings - Fork 0
/
machsweep.m
91 lines (74 loc) · 1.76 KB
/
machsweep.m
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
83
84
85
86
87
88
89
clear all
format compact
close all
load('xcp.mat')
load('props.mat')
load('Cp0.mat')
load('Cp500.mat')
load('Cp700.mat')
load('Cp785.mat')
nseg = length(xcp);
figure(1)
clf
hold on
for iseg=1:nseg
if( ~props{iseg} )
plot( xcp{iseg}, -Cp0{iseg} );
end
end
hold off
ylabel('-C_p Compressible')
figure(2)
clf
hold on
xsh = min(xcp{1});
dx = max(xcp{1})-min(xcp{1});
plot( (xcp{1}-xsh)./dx, Cp0{1}, '--', 'LineWidth', 1 );
plot( (xcp{1}-xsh)./dx, Cp500{1}, 'k--', 'LineWidth', 1 );
plot( (xcp{1}-xsh)./dx, Cp700{1}, 'g--', 'LineWidth', 1 );
plot( (xcp{1}-xsh)./dx, Cp785{1}, 'r--', 'LineWidth', 1 );
hold off
ylabel('C_p Compressible')
legend('M=0','M=0.5','M=0.7','M=0.785') %
ax=axis;
ax(3)=-1.25;
ax(4)=1.25;
axis(ax)
figure(3)
clf
hold on
plot( xcp{2}, Cp0{2}, '-', 'LineWidth', 1 );
plot( xcp{2}, Cp500{2}, 'k-', 'LineWidth', 1 );
plot( xcp{2}, Cp700{2}, 'g-', 'LineWidth', 1 );
plot( xcp{2}, Cp785{2}, 'r-', 'LineWidth', 1 );
hold off
ylabel('C_p Compressible')
legend('M=0','M=0.5','M=0.7','M=0.785') %
ax=axis;
ax(3)=-1.25;
ax(4)=1.25;
axis(ax)
figure(4)
clf
hold on
xsh = min(xcp{1});
dx = max(xcp{1})-min(xcp{1});
plot( (xcp{1}-xsh)./dx, Cp0{1}, '--', 'LineWidth', 1 );
plot( (xcp{1}-xsh)./dx, Cp500{1}, 'k--', 'LineWidth', 1 );
plot( (xcp{1}-xsh)./dx, Cp700{1}, 'g--', 'LineWidth', 1 );
plot( (xcp{1}-xsh)./dx, Cp785{1}, 'r--', 'LineWidth', 1 );
xsh = min(xcp{2});
dx = max(xcp{2})-min(xcp{2});
plot( (xcp{2}-xsh)./dx, Cp0{2}, '-', 'LineWidth', 1 );
plot( (xcp{2}-xsh)./dx, Cp500{2}, 'k', 'LineWidth', 1 );
plot( (xcp{2}-xsh)./dx, Cp700{2}, 'g', 'LineWidth', 1 );
plot( (xcp{2}-xsh)./dx, Cp785{2}, 'r', 'LineWidth', 1 );
hold off
ylabel('C_p Compressible')
legend('M=0','M=0.5','M=0.7','M=0.785') %
ax=axis;
ax(1)=0;
ax(2)=1;
ax(3)=-1.25;
ax(4)=1.25;
axis(ax)