登录论坛

查看完整版本 : [MATLAB数学相关] 帮忙运行一下,我的2009b版本老不行,非常感谢!


Heavene23
2011-02-13, 12:19
求速度vv最大时(此时角度e=90°),a与b的关系,
clc;clear;
syms a b e o p g m H1 H2 v u V0

o=atan(b/a*sqrt(tan(e)));%o和e是角度
pretty(o)
%p=1/(a*b/(a*a*(sin(o))^2+b*b*(cos(o))^2)^1.5);
p=1/(a*b/(a*a*(sin(atan(b/a*sqrt(tan(e)))))^2+b*b*(cos(atan(b/a*sqrt(tan(e)))))^2)^1.5)
pretty(p)

vv=dsolve('g*(cos(e)-u*sin(e))-(H1/m*v+H2/m*v*v)-u*v*v/p=v/p*Dv','v(0)=V0','e');
%vv=dsolve('Dv=p*g *(cos(e)-u*sin(e))-v*u','v(0)=V0','e');
%pretty(vv)
f=inline(vv,'e')
vab=f(pi/2);
dva=diff(vab,a);
a=solve(dva);
pretty(a)
计算结果是
Warning: Explicit solution could not be found.
> In dsolve at 101
In quxian at 19

f =

Inline function:
f(e) = []

Warning: List of equations is empty.
> In solve at 70
In quxian at 25

+--+
+--+

独轩居士
2012-09-27, 09:32
/ 1/2 \
| b tan(e) |
atan| ----------- |
\ a /

p =

(b^2/((b^2*tan(e))/a^2 + 1) + (b^2*tan(e))/((b^2*tan(e))/a^2 + 1))^(3/2)/(a*b)


3
-
/ 2 2 \2
| b b tan(e) |
| ------------- + ------------- |
| 2 2 |
| b tan(e) b tan(e) |
| --------- + 1 --------- + 1 |
| 2 2 |
\ a a /
----------------------------------
a b
Warning: Explicit solution could not be found.
> In dsolve at 101

f =

Inline function:
f(e) = []

Warning: List of equations is empty.
> In solve at 70

+--+