|
马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。
您需要 登录 才可以下载或查看,没有账号?我要加入
x
程序每次运行都提示
??? Input argument "V" is undefined.
Error in ==> F_Ft at 28
F_t = (0.613*V^2/1000) * diag(A_t) * Cp_tr; % units in example are kN
请问该怎么改?谢谢!
源程序如下
function [F_t] = F_Ft(Cp_tr,V)
global flnTaps taps Ntaps Npoints
% This function calculates the wind load matrix, F_t (Ntaps x Npoints), for dynamic MDOF system
%%%%%%%%%%%%%%%%% Pressure tap information : flnTaps, Page 2, [Ntaps X 5] %%%%%%%%%%%%%%%%%%%%
% Load flnTaps and check for errors
clear fid; fid=fopen(flnTaps);
if fid == -1
errordlg('Unable to open ''flnTaps'' - Page 2')
error ('Unable to open ''flnTaps'' - Page 2')
end
fclose(fid); clear fid;
[taps]=[]; load (flnTaps)
if isempty(taps)==1
errordlg('Variable ''taps'' not defined. See flnTaps on Page Two')
error ('Variable ''taps'' not defined. See flnTaps on Page Two')
end
if size(taps,1) ~= Ntaps | size(taps,2) ~= 5
errordlg('Variable ''taps'' not properly sized. (Ntaps x 5)')
error ('Variable ''taps'' not properly sized. (Ntaps x 5)')
end
A_t = taps(:,5); % Tributary areas in last column of 'taps'
%%%%%%%%%%%%%%%% Calculate the wind load matrix, F_t (Ntaps x Npoints) %%%%%%%%%%%%%%%%%%%%%
F_t = zeros(Ntaps,Npoints); % Initialize the wind forces array
% Change the following lines to accomodate the proper F_t
% 1. Cp_tr contains pressure coefficients
F_t = (0.613*V^2/1000) * diag(A_t) * Cp_tr; % units in example are kN
'NOTE: 1/2 rho V^2 Cp(t) USED!!! F_t in kN (F_Ft.m)'
% 2. Cp_tr contains pressures
% F_t = diag(A_t) * Cp_tr;
% 'NOTE: Cp(t) * A USED!!! (F_Ft.m)'
% 3. Cp_tr contains forces
% F_t = Cp_tr;
% 'NOTE: Cp(t) USED!!! (F_Ft.m)' |
|