Is it possible to call Matlab from Java asynchronously ?

1 vue (au cours des 30 derniers jours)
Dang Manh Truong
Dang Manh Truong le 21 Juin 2017
Réponse apportée : Jan le 21 Juin 2017
Hi, I am aware of utilities like https://code.google.com/archive/p/matlabcontrol/wikis/Walkthrough.wiki where you can call a Matlab function from Java. But is it possible to call Matlab asynchronously? I mean you call a Matlab function, but the catch is that it has no return arguments, it just does whatever it is intended to do. After the function is called, Matlab just does what is does, and control is given back to Java immediately (without waiting for said function to complete). Is there any way to do this? Thank you very much :)

Réponses (1)

Jan
Jan le 21 Juin 2017
See e.g. http://www.rgagnon.com/javadetails/java-0014.html for starting a process in Java. Then provide the function to be run using the -r flag:
"matlab.exe -r YourFunction"

Catégories

En savoir plus sur Java Package Integration dans Help Center et File Exchange

Tags

Aucun tag saisi pour le moment.

Community Treasure Hunt

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

Start Hunting!

Translated by