Question-and-Answer Resource for the Building Energy Modeling Community
Get started with the Help page
Ask Your Question

SFreu's profile - activity

2018-04-11 08:00:02 -0500 marked best answer GenOpt - Starting dymosim.exe with .mat file as input file

Deary erveryone,

I have some issues using GenOpt together with Dymola. In my case I want to start the dymosim.exe with a .mat file as input file and not with a .txt file (typical dsin.txt). I have changed the entries in the initialization file for the template and input file from dsin.txt to the given .mat file and changed the command for calling the dymosim.exe with the .mat file. When I run the dymosim.exe with the .mat file from the command line it works.

However, when GenOpt copies the .mat file into the temporary folder (tmp-genopt-run-) the file seems to be corrupted somehow. The log file shows the following error:

... Error message from dymosim.exe
Error reading matrix header from file "dymosim_input.mat":
End-Of-File reached.

If I try to open the copied .mat.file with Matlab I get an error as well:

Error using load
Number of columns on line 2 of ASCII file
C:\...\dymosim_input.mat must be the same as previous lines.

Does anyone have an idea why the copied .mat file is corrupted? I would highly appreciate any suggestions.

2018-04-11 08:00:02 -0500 received badge  Scholar (source)
2018-04-11 07:59:58 -0500 commented answer GenOpt - Starting dymosim.exe with .mat file as input file

Thank you, Michael! The clue to use CallParameter did solve the problem and now it works.

2018-04-06 09:48:49 -0500 received badge  Student (source)
2018-04-06 08:45:23 -0500 asked a question GenOpt - Starting dymosim.exe with .mat file as input file

GenOpt - Starting dymosim.exe with .mat file as input file Deary erveryone, I have some issues using GenOpt together wi