フィルターのクリア

I need to pull data from an excel file ino MATlab which I made happen I was also able to pull values from the table but now I don't know how to use these values in my equation

1 回表示 (過去 30 日間)
% design the multiplication matrix
k = [ (cos(al))^2, (sin(al))^2, -sin(2*al) ; (sin(al))^2, (cos(al))^2, sin(2*al) ; .5*sin(2*al), -.5*sin(2*al), (cos(al))^2];
disp("The multiplication matrix is displayed below");
disp(k);
% now we multiply the matrix
I = k * [Ixx ; Izz; Ixz] ;
>> table2array(T ({'IxxB (slugft2)','IzzB (slugft2)','IxzB (slugft2)'}, {'a'}))
ans =
948
1967
0
>> table2array(T ({'Angle of attack, u\ (deg)'}, {'a'}))
ans =
5.4000
I pulled this values from my excel file but how do I use them in my "k" and "I" equation? I am sorry if thats an easy answer
  1 件のコメント
AndresVar
AndresVar 2022 年 2 月 16 日
assign the output of table2array to a variable, btw cos and sin need angle in radians. for example:
al = table2array(T ({'Angle of attack, u\ (deg)'}, {'a'}))
al = deg2rad(al); % alpha in radians
Ib = table2array(T ({'IxxB (slugft2)','IzzB (slugft2)','IxzB (slugft2)'}, {'a'}))

サインインしてコメントする。

回答 (0 件)

カテゴリ

Help Center および File ExchangeLanguage Fundamentals についてさらに検索

製品


リリース

R2020b

Community Treasure Hunt

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

Start Hunting!

Translated by