%%%%%%%%%问题一模型
syms x
y1=(acos(1-4*x)-(8*x-16*x^2)^(1/2)*(1-4*x));
s=2*pi*x;
Y1=abs(y1-s);
Y2=Y1/s;
figure;
ezplot(y1,[0 0.5])
hold on
ezplot(s,[0 0.5])
figure;
ezplot(Y2,[0 0.5])
axis([0 0.5 0 2.5])
y2=2*(acos(1-2*x)-(4*x-4*x^2)^(1/2)*(1-2*x));
Y3=abs(y2-s);
Y4=Y3/s;
subplot(121)
ezplot(Y3,[0 0.5])
axis([0 0.5 0 2.5])
subplot(122)
ezplot(Y4,[0 0.5])
axis([0 0.5 0 2.5])
figure;
ezplot(y2,[0 0.5])
hold on
ezplot(s,[0 0.5])
%%%%%%%%%%%%%%%程序一
syms x
y1=(2*x-4*x^2)^1/2;
Y1=int(y1); %不定积分
figure;
ezplot(Y1,[0 0.5]) %曲线
y2=x^2*16*pi/6;
figure;
ezplot(y2,[0 0.5])
y3=1.6*x+asin(0.05)-0.2*0.96^1/2;
figure;
ezplot(y3,[0 0.5])
figure;
y4=2*(acos(1-4*x)-(8*x-16*x^2)^(1/2)*(1-4*x));
ezplot(y4,[0 0.5])
%%%%%%%%%%%%%%%%改进的线性函数
syms x
y=2*pi*x;
y1=(acos(1-4*x)-(8*x-16*x^2)^(1/2)*(1-4*x));
ezplot(y,[0 0.48])
hold on
ezplot(y1,[0.48 0.5])
axis([0 0.5 0 4])
%%%%%%%%%%%%%%%%积分求面积
n=input('请输入: ');
y(1)=1/n;
for i=1:n
y(i+1)=y(i)+(2*sqrt(1-(sqrt(7)/4/n*i)^2)*sqrt(7)/4/n);
end
p=2*y(n);
double(simplify(p))