Info

この質問は閉じられています。 編集または回答するには再度開いてください。

# Trying to use the values for 3 separate vectors and add them into a for loop to answer my equation for for each different value. Please help.

1 回表示 (過去 30 日間)
Panfilo Armas 2020 年 11 月 5 日

Hi! I'm trying to solve for Po with 3 vectors. Idk ifI'm doing this correctly or not. I have the code I'm trying to run below.
fy = [200; 250; 300];
fc = [15; 30; 50; 70];
Ac = [0.0066 0.0055:0.029 0.0266];
for i = 1:length(fy)
for j = 1:length(fc)
for k =1:length(Ac)
Po(i,j,k) = (fy(j).*Ast)+(alpha1.*fc(i)*Ac(k));
end
end
end
##### 4 件のコメント2 件の古いコメントを表示2 件の古いコメントを非表示
Panfilo Armas 2020 年 11 月 6 日
I apoloigze.
it is alpha1=0.95; and Ast=Atot-Ac; with Atot = pi*(100/2)^2; and Ac = (((100-(2*4))/2)^2)*pi
Mathieu NOE 2020 年 11 月 6 日
there is something wrong in your inputs
you have now given two definitions of Ac :
Ac = [0.0066 0.0055;0.029 0.0266] dim : 2 x2
or
Ac = (((100-(2*4))/2)^2)*pi ?? dim : 1 (scalar)

### Community Treasure Hunt

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

Start Hunting!

Translated by