Message Boards Message Boards

0
|
5165 Views
|
3 Replies
|
2 Total Likes
View groups...
Share
Share this post:

Error connecting SystemModeler and Mathematica

Posted 3 years ago

Hello,

I am getting the following error message when I try to run the "SystemModeler[]" command (with and without an argument) in Mathematica:

SystemModeler::ncor: SystemModeler is a full graphical modeling and simulation environment available in the Wolfram SystemModeler product.

Other symptoms of the problem are:

1.) System model objects created in Mathamatica with the command "CreateSystemModel" can not be found in the SystemModeler ModelCenter.

2.) The "copy as wolfram language object" button in SystemModeler does not copy the model in its current state. It only copys it the way the Model was originally loaded. Changes are not regarded.

Both SystemModeler and Mathematica are installed (and reinstalled) and working well on theire own.

Does anyone know what can cause this issue, and how I can fix it?

Thanks in adavance. Mortimer

3 Replies

I believe technical support is in the process of reaching back to you on this issue. The first check is to see whether the versions of both products match to the first decimal, which is a necessary condition for the link to work.

For the link between Mathematica version 12.1.1 and System Modeler version 12.1.0, the following can help

PacletDisable /@ PacletFind["WSM" -> "12.2.0"];
PacletDisable /@ PacletFind["WSMLink" -> "12.2.0"];

systemModelerInstallationPath = "/usr/local/Wolfram/SystemModeler/12.1/";
PacletDirectoryLoad[FileNameJoin[{systemModelerInstallationPath, "Mathematica"}]]

, where systemModelerInstallationPath should be adapted to match the installation path of System Modeler on your machine. The PacletDirectoryLoad is per session, while the PacletDisable is permanent, so the PacletDirectoryLoad lines can be placed in Kernel/init.m inside $UserBaseDirectory. Alternatively, they can be evaluated manually once at the beginning of every kernel session.

Another possibility is that the compiler for System Modeler has not been properly configured, see https://reference.wolfram.com/language/tutorial/CompilerForSystemModeling.html

POSTED BY: Sergio Vargas

Thank you so much for the fast response.

Your code works like a charm! Unfortunately, but I do not really understand where I can find the user base directory in which I have to place the code. Could you provide a little bit more details about that.

Again, big thanks for the fast response

Best regards, Mortimer Dockhorn

Was able to solve it.

Thank you again!

Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract