用matlab求椭圆周长,数值积分法。椭圆形式如下:x^2/4+y^2/9=1
1个回答
展开全部
半椭圆
y=3√(1-x^2/4)
椭圆周长=2×∫√(1+y′²)dx
matlab
>> syms x
>> y=3*(1-x^2/4)^(1/2);
>> y1=diff(y,x);
>> f=(1+y1^2)^(1/2)
f =
(1 - (9*x^2)/(16*(x^2/4 - 1)))^(1/2)
>> ss=@(x)(1 - (9*x.^2)./(16*(x.^2/4 - 1))).^(1/2)
ss =
@(x)(1-(9*x.^2)./(16*(x.^2/4-1))).^(1/2)
>> S=2*quad(ss,-2,2)
S =
15.8655
y=3√(1-x^2/4)
椭圆周长=2×∫√(1+y′²)dx
matlab
>> syms x
>> y=3*(1-x^2/4)^(1/2);
>> y1=diff(y,x);
>> f=(1+y1^2)^(1/2)
f =
(1 - (9*x^2)/(16*(x^2/4 - 1)))^(1/2)
>> ss=@(x)(1 - (9*x.^2)./(16*(x.^2/4 - 1))).^(1/2)
ss =
@(x)(1-(9*x.^2)./(16*(x.^2/4-1))).^(1/2)
>> S=2*quad(ss,-2,2)
S =
15.8655
本回答被提问者采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询