- Index
- » Users
- » jorodrg
- » Profile
Posts
Posts
The function must work, but if you get some errors, make sure your Matlab version is compatible with the function one.
Hi
To use this function, first you have to simulate the model in OpenModelica. If the option "Output Format" is selected with "mat" (by default), in the path "C:\Users\User_Name\AppData\Local\Temp\OpenModelica\OMEdit" it will appear a file with the extension .mat and "modelname_res".
Open a Matlab session and copy this file into the current Matlab directory. Now you can run the function from the command line.
Cheers,
Jorge
Hi,
I'm using OpenModelica version 1.12.0 for 64bits and I have developed an hydraulic library. In order to simulate the model of a press circuit, I select symsolver in it's backward configuration. Most of the simulation was done properly, but when the model reaches some points (near cero flow rate in the pipelines) the simulation slows and appear repeateadly the message: "Warning: maximal number of iteration reached but no root found". After this stage, the simulation stop and exit with code -1.
I done some research and I think the problem comes from not having a fixed cost simulation on the non-linear equations. Is there a way to limit the nonlinear iterations or use fixed-cost runtime on the simulation?
Thanks,
Jorge
Hello,
In order to run an hydraulic press model, I'm trying different OM compilers. After some research, the solver which achieve a better result is symSolver configured in backward mode (impEuler). In spite of running the model, when some non-linear systems appear it crashes and stop the simulation.
After some investigation, I deduced the problem comes from needing to specify the maximum number of nonlinear steps and mode iterations for transient initialization. In this situation, if the system does not converge upon reaching these numbers, it ignores the failure and goes to the next step.
Is there any way to realize this configuration?
Cheers,
Jorge
Thanks for your answer, the problem is solved now.
Cheers,
Jorge
Sorry for the missing information.
I have used OM version 1.11.0 and the nightly build 1.12.0 for 64bits to create the FMU and Simulink version 8.7 for MATLAB R2016a also with 64 bits.
Thanks,
Jorge
Hello,
I have created a FMU with OpenModelica and exported it into Simulink. To import the model into Simulink I used FMIKit for Simulink, which was able to load it, howhever when the project is executed, I get the following message:
Error in 'test/filename' while executing C MEX S-function 'sfun_fmurun', (mdlStart), at time 0.0.
Unexpected Standard exception from MEX file.
What() is:Could not load shared library
I imported the model back into OM and it runs, so I'm hesitating the problem is I lack to include another library or dll in order to run the model in Simulink.
Any hint of what I'm missing?
Thanks in advice,
Jorge
- Index
- » Users
- » jorodrg
- » Profile