Index exceeds the number of array elements. Index must not exceed 1.

1 回表示 (過去 30 日間)
A Poyser
A Poyser 2022 年 10 月 27 日
コメント済み: A Poyser 2022 年 10 月 27 日
This line of code is giving me the above error message
T = k^2 * Em(k) * (((k^2 - mean_nu) * E(k) + mean_nu *crack_aspect_ratio^2 * Gm * k)^-1 + (( k^2 + (Mean_nu * crack_aspect_ratio^2) ) * Em * (k) - Mean_nu * crack_aspect_ratio^2 * Gm * k)^-1)
Unrecognized function or variable 'k'.
Could someone please explain how to rectify the problem

採用された回答

Torsten
Torsten 2022 年 10 月 27 日
You use Em(k) and Em * (k) in this line of code. Both cannot be correct, I guess.
Further check out whether E(k) is correct: E is treated as an array where the k-th element is referenced or as a function that is called with input argument 1.
  1 件のコメント
A Poyser
A Poyser 2022 年 10 月 27 日
I realised this shortly after writing the question. Thanks.

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeMatrix Indexing についてさらに検索

タグ

製品


リリース

R2022b

Community Treasure Hunt

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

Start Hunting!

Translated by