*ARCHIVED* development moved to aircraft-studio.
1
function z = get_int(,,)
2
3
M = 0.02;
4
P = 0.4;
5
T = 0.12;
6
a0 = 0.2969;
7
a1 = -0.126;
8
a2 = -0.3516;
9
a3 = 0.2843;
10
a4 = -0.1015;
11
12
13
%evaluate the integral of camber line, depending on xi and xf related to P
14
15
if xf <P
16
intCamb = M/P^2*(2**^2/2-^3/3) - M/P^2*(2**^2/2-^3/3);
17
elseif xi<P
18
intCamb = (/(1-)^2)*((1-2*)*+2**^2/2-^3/3) - (/(1-)^2)*((1-2*)*+2**^2/2-^3/3);
19
intCamb = intCamb + M/P^2*(2**^2/2-^3/3) - M/P^2*(2**^2/2-^3/3);
20
else
21
intCamb = (/(1-)^2)*((1-2*)*+2**^2/2-^3/3) - (/(1-)^2)*((1-2*)*+2**^2/2-^3/3);
22
end
23
24
% do integral on thickness line
25
%z_thickness = (/0.2)*(*^.5+*+*^2+*^3+*^4);
26
27
intThickness = (/0.2)*(*^1.5/1.5+*^2/2+*^3/3+*^4/4+*^5/5);
28
intThickness = intThickness - (/0.2)*(*^1.5/1.5+*^2/2+*^3/3+*^4/4+*^5/5);
29
30
% combine both integral results to get total integral
31
if u == 1
32
z = intCamb + intThickness;
33
else
34
z = abs(-);
35
end