Execution of script as a function is not supported
1,257 ビュー (過去 30 日間)
古いコメントを表示
Hello,
I donwloaded a function online. It works fine until the line 58 where I have "Execution of script mix_2d_lp_fonc as a function is not supported". I don't know why, I am sure I am in the correct folder (I wrote which...).
I would be gratefull for your assistance
0 件のコメント
採用された回答
Stephen23
2023 年 2 月 21 日
The problem is that you named the script mix_2d_lp_fonc
Then when the script gets to this line:
fcn_handles = mix_2d_lp_fonc(problem(K))
it tries to call the function mix_2d_lp_fonc.... but cannot, because that is what you called your script.
Solution: Give your script another filename.
0 件のコメント
その他の回答 (3 件)
Keerthana
2024 年 5 月 7 日
Execution of script bilinear as a function is not supported:
/MATLAB Drive/bilinear.mlx
1 件のコメント
Stephen23
2024 年 5 月 7 日
You named your script BILINEAR, and then within that script you attempted to call a function named BILINEAR, e.g. this one:
Of course that will not work, because you named your script BILINEAR.
Solution: rename your script to something else, e.g. MY_BILINEAR.
Luca Ferro
2023 年 2 月 21 日
編集済み: Luca Ferro
2023 年 2 月 21 日
there is no definition of the function mix_2d_lp_fonc(), at least not in the file you shared. It's just the name of the script itself, so you could call it but cannot pass arguments as done at that line mix_2d_lp_fonc(problem(K)).
My guess would be that the first line, so teh declaration of the function, is missing somehow
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Startup and Shutdown についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!