matlab求隐函数导函数方程,如何用Matlab画隐函数(带参数)的方程

没有什么太好的办法.

【1】解第一个方程,用1-(cos(x))^2=(sin(x))^2

>> x=solve('2*(1-(cos(x))^2)*cos(x)-cos(x)+cos(x0)-sin(x0)=0','x')

x =

[ acos(1/6*(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)+1/(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3))]

[ acos(-1/12*(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)-1/2/(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)+1/2*i*3^(1/2)*(1/6*(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)-1/(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)))]

[ acos(-1/12*(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)-1/2/(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)-1/2*i*3^(1/2)*(1/6*(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)-1/(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)))]

【2】变换ctan为1/tan

>>y='(sin(x)-cos(x)-sin(x0)+cos(x0))*(1+1/tan(x0))'

【3】替换y中的x,为x0的变量

>> y1=subs(y,'x',x)

y1 =

[ ((1-(1/6*(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)+1/(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3))^2)^(1/2)-1/6*(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)-1/(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)-sin(x0)+cos(x0))*(1+1/tan(x0))]

[ ((1-(-1/12*(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)-1/2/(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)+1/2*i*3^(1/2)*(1/6*(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)-1/(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)))^2)^(1/2)+1/12*(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)+1/2/(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)-1/2*i*3^(1/2)*(1/6*(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)-1/(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3))-sin(x0)+cos(x0))*(1+1/tan(x0))]

[ ((1-(-1/12*(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)-1/2/(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)-1/2*i*3^(1/2)*(1/6*(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)-1/(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)))^2)^(1/2)+1/12*(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)+1/2/(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)+1/2*i*3^(1/2)*(1/6*(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3)-1/(54*cos(x0)-54*sin(x0)+6*(-6+81*cos(x0)^2-162*cos(x0)*sin(x0)+81*sin(x0)^2)^(1/2))^(1/3))-sin(x0)+cos(x0))*(1+1/tan(x0))]

【4】用ezplot分别画图

>> ezplot(y1(1))

>> ezplot(y1(2))

>> ezplot(y1(3))

  • 1
    点赞
  • 2
    收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
©️2022 CSDN 皮肤主题:游动-白 设计师:我叫白小胖 返回首页
评论
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、C币套餐、付费专栏及课程。

余额充值