怎样画出以下函数的图形? 。

我用的是32位R2009a,32位win7系统
这是程序代码
x= 0:0.1:100;
y1 = (sin(x)+sinh(x))/(cos(x)+cosh(x))
y2 = (1+cos(x).*cosh(x))/((cos(x)+cosh(x)).^2)
y3 = (sin(x)-sinh(x))/(cos(x)+cosh(x))
y4 = sin(x).*sinh(x)/((cos(x)+cosh(x)).^2)
y = 6/(x^2).*((1-3/(2*x).*y1+y2).^2+(3/(2*x).*y3+y4).^2).^(1/2)
plot(x,y)
运行后的结果是>> x = 0:0.1:100;
y1 = (sin(x)+sinh(x))/(cos(x)+cosh(x));
y2 = (1+cos(x).*cosh(x))/((cos(x)+cosh(x)).^2);
y3 = (sin(x)-sinh(x))/(cos(x)+cosh(x));
y4 = sin(x).*sinh(x)/((cos(x)+cosh(x)).^2);
y = 6/(x^2).*((1-3/(2*x).*y1+y2).^2+(3/(2*x).*y3+y4).^2).^(1/2);
plot(x,y)
??? Error using ==> mpower
Matrix must be square.

 採用された回答

pelifih
pelifih 2022 年 11 月 17 日

0 投票

x = 0:0.1:100;
y1 = (sin(x)+sinh(x))./(cos(x)+cosh(x));
y2 = (1+cos(x).*cosh(x))./((cos(x)+cosh(x)).^2);
y3 = (sin(x)-sinh(x))./(cos(x)+cosh(x));
y4 = sin(x).*sinh(x)./((cos(x)+cosh(x)).^2);
y = 6./(x.^2).*((1-3./(2*x).*y1+y2).^2+(3./(2*x).*y3+y4).^2).^(1/2);
plot(x,y)

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File Exchange启动和关闭 についてさらに検索

タグ

質問済み:

2022 年 11 月 17 日

回答済み:

2022 年 11 月 17 日

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!