📄 triratio.m
字号:
function [ratio]=triratio(base,height)
% TRIRATIO.M Compute and plot the ratio of area to perimeter of
% isosceles triangle given base and height
% Call: [ratio]=triratio(base,height)
base2=0.5*base;
area=base2.*height;
perimeter=base+2*sqrt(base2.^2+height.^2);
ratio=area./perimeter;
%
% Note: The preamble and statements could use a few more comments.
%
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -