A peculiar problem when using system command to run a c shell script from matlab.
古いコメントを表示
I need to run a shell script from matlab by using system command (or unix, or !), but none of the FORTRAN executable files that I need actually works with "system", even though it still gives me status flag as 0, which usually means the code works well but it is obviously not the case for today. Has anyone ran into similar problems before? The shell script works perfectly fine otherwise. I never ran into such a strange problem with "system" command before, and I have not found anything vaguely related to this from the Internet. :(
6 件のコメント
Walter Roberson
2012 年 7 月 15 日
Is there a reason you are not using
!fortranExe1 var1 var2; fortranExe2 var1 var2
or the system() equivalent? Both commands on the same line and no explicit invocation of the shell?
Do these executables perform graphics?
Shan Dou
2012 年 7 月 15 日
Walter Roberson
2012 年 7 月 15 日
I wonder... this output, is it maybe being sent to stderr instead of stdout ? Help information is often sent to stderr.
Shan Dou
2012 年 7 月 15 日
Shan Dou
2012 年 7 月 16 日
採用された回答
その他の回答 (2 件)
1 件のコメント
Walter Roberson
2012 年 7 月 16 日
I think it's worth reporting a bug.
Walter Roberson
2012 年 8 月 14 日
0 投票
Ben Ward posted a response from MATLAB showing how to work with this issue; see http://www.mathworks.co.uk/matlabcentral/answers/44388-or-system-or-unix-input-redirection
カテゴリ
ヘルプ センター および File Exchange で Fortran with MATLAB についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!