Archived OpenModelica forums. Posting is disabled.

Alternative forums include GitHub discussions or StackOverflow (make sure to read the Stack Overflow rules; you need to have well-formed questions)


Forgot password? | Forgot username? | Register

Parameter Variation - Interface to Matlab

Parameter Variation - Interface to Matlab

Hello,

I wanted to compile and run a OM-Model by Matlab and import the OM-Model to Matlab for a parameter variation by Matlab. Is there a possibility to do so?

I found until yet a Interface from Christian Schaad from 2012 to do exactly this, but the HelloWorld-Example of this Interface doesn't work. A few files won´t be found by the script.
Is it still working with Matlab R2016b and OMEdit v1.11.0 or are there problems with the compatibility? Does anybody used this script and the HelloWorld-Example successfully?



The occured errors are the following ones:

Command Window:

Warning: File 'HelloWorld.test.h' not found.
> In omcleanup (line 12)
  In om_mat_example (line 15)
Warning: File '_HelloWorld.test.h' not found.
> In omcleanup (line 19)
  In om_mat_example (line 15)
Warning: File 'HelloWorld.test.cpp' not found.
> In omcleanup (line 21)
  In om_mat_example (line 15)
Replaced line number 91, parameter Hello1.a with 2
Warning: File 'HelloWorld.test_res.mat' not found.
> In omrun (line 12)
  In om_mat_example (line 28)

ans =

  -1.0737e+09

Error using load
Unable to read file 'HelloWorld.test_res.mat'. No such file or directory.

Error in omimport (line 11)
load ([modelname,'_res.mat']);

Error in om_mat_example (line 30)
omimport(modelname);  % Read results into Matlab workspace

Thanks for helping.

Edited by: NR - Oct-24-17 15:22:13
There are 0 guests and 0 other users also viewing this topic
You are here: