How do I run MATLAB from the mac terminal?
409 ビュー (過去 30 日間)
古いコメントを表示
Cristian Sanchez Montesinos
2019 年 2 月 3 日
コメント済み: Marco cazzaniga
2023 年 2 月 16 日
I am trying to run MATLAB from the mac OS X terminal. I'm using macOS Mojave version 10.14.2, and MATLAB R2018b. What I'm doing is:
- I open the terminal
- Go to /Applications
- pe MATLAB_R2018
However, I get the following:
-bash: MATLAB_R2018b: command not found
Can someone help me with this?
Thanks.
0 件のコメント
採用された回答
Ken Atwell
2019 年 2 月 4 日
I do this:
open /Applications/MATLAB_R2018b.app/
その他の回答 (2 件)
Walter Roberson
2019 年 2 月 5 日
alias matlab="/Applications/MATLAB_R2018b.app/bin/matlab -nojvm -nodesktop"
I put the above in my ~/.bash_profile
3 件のコメント
Walter Roberson
2019 年 2 月 9 日
Yes. If you are using the default bash shell then when you start an interactive session the .bash_profile in your home directory is sourced. The command I show sets up a command named matlab to launch r2018b in terminal mode. It can be invoked by that name from the terminal no matter where you are cd to . It is effectively a shortcut for typing in the right hand side.
Peiwei Liu
2021 年 10 月 20 日
In terminal on mac, type this:
/Applications/Polyspace/R2019b/bin/matlab; exit;
Please adjust this to your own path. Works!
参考
カテゴリ
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!