e421.asv
来自「学习Matlab循环语句的好例子」· ASV 代码 · 共 24 行
ASV
24 行
% Script file: E421.m
% Purpose:
% Write a program to determine the idistance d at which
% to attach the cable to the pole to minimize the tension on the cable.
% in d=1:1:7,also plot the tension on the cable as a function of d.
% Record of revisions
% Date Programmer Description of change
% ========== ================= ==========================
% 13/06/08 ZMW Original code
% Define Variables
% T ------the tension on the cable
% d ------ the distance along the pole at which the cable is attached
% ii --------the index
% Constants
lc=8;
lp=8;
W=200;
ii=1;
for d=1:1:7
T(ii)=W*lc*lp./(d*sqrt(lp^2-d.^2));
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?