马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。
您需要 登录 才可以下载或查看,没有账号?我要加入
x
inline函数提示是输入必须为字符串,不过没有看出哪儿错,请教一下各位~~,谢谢- ………………………………
- syms phis2 phitheta thetas phis; %定义符号函数:
- phi2 = q2s * phis;
- phitheta = phis + ( thetas0 + thetas );
- y2 = linspace(y2min,y2max,10); %产生等差数列,y2为y2min至y2max之间共10个数
- options = optimset('Display','off');
- ……………………
- for k = 1:10
- ysc2 = y2(k) + (rbs*(sin(phi2)*(sin(phitheta)-thetas*cos(phitheta))+cos(phi2)/(q2s*cos(phitheta))));
- ysc2 = vpa(subs(ysc2),4);
- yfc2 = inline('ysc2'); %已按花如月建议修改
- thetaslist(k,:) = linspace(thetaslimits(k,1),thetaslimits(k,2),10); %#ok<AGROW> %thetas的取值矩阵
- for m = 1:10
- phisnum(k,m) = fzero(yfc2,0,options,thetaslist(k,m)); %#ok<AGROW> %phis的取值矩阵
- end
- end
- ………………………………
复制代码 错误提示是:
ysc2 =-300.+46.98*sin(.2000*phis)*(sin(phis+.6364e-1+thetas)-1.*thetas*cos(phis+.6364e-1+thetas))+234.9*cos(.2000*phis)/cos(phis+.6364e-1+thetas)
??? Error using ==> inline.inline at 47
Input must be a string.
Error in ==> FaceGear at 58
yfc2 = inline(ysc2);
[ 本帖最后由 eight 于 2007-10-8 11:10 编辑 ] |