How i divide a Constant with a Matrix ?

9 ビュー (過去 30 日間)
nikola oljaca
nikola oljaca 2021 年 3 月 21 日
コメント済み: nikola oljaca 2021 年 3 月 21 日
x=[-20:0.5:20]
gzx = 2*G*deltaMzylinder*(zs/(zs^2+x.^2))
plot(x,gzx)
Error using /
Matrix dimensions must agree.

採用された回答

Cris LaPierre
Cris LaPierre 2021 年 3 月 21 日
We would need to know what zs is to say for certain, but the most likely fix is to use elementwise division, "./".
  3 件のコメント
nikola oljaca
nikola oljaca 2021 年 3 月 21 日
really nice it worked i am so happy
nikola oljaca
nikola oljaca 2021 年 3 月 21 日
PS : zs is the depth to my center gravity

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeLinear Algebra についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by