Opened 5 years ago

Last modified 3 years ago

#5638 new defect

The function readSimulationResultVars does not return the correct results.

Reported by: Niklas Worschech Owned by: somebody
Priority: high Milestone:
Component: Interactive Environment Version: v1.13.2
Keywords: OMC API, readSimulationResultVars Cc:

Description

For the attached file filterSimulationResults.mat the function readSimulationResultVars does not return the result variables.
With the use of these calls we try to convert the mat file into a csv file.

vars:=readSimulationResultVars("filterSimulationResults.mat",false,false);
getErrorString();
filterSimulationResults("filterSimulationResults.mat","filterSimulationResults.csv",vars);
getErrorString();

But the converted csv file only includes the variables "_derdummy","_dummy"

Attachments (1)

filterSimulationResults.mat (14.6 KB ) - added by Niklas Worschech 5 years ago.

Download all attachments as: .zip

Change History (8)

by Niklas Worschech, 5 years ago

Attachment: filterSimulationResults.mat added

comment:1 by Francesco Casella, 5 years ago

@niklwors, this kind of tasks can be easily carried out usin python. Is it critical for you to have this functionality in OpenModelica scripts?

comment:2 by Niklas Worschech, 5 years ago

Is there a python script that can do this functionality?

comment:3 by Martin Sjölund, 5 years ago

That's because your file only contains parameters or time-independent variables (data_1 matrix) and not continuous-time variables (data_2).

You could just output them to csv-file if that is necessary by calling val() on them.

Or Python packages such as:
https://www.j-raedler.de/projects/DyMat/
http://kdavies4.github.io/ModelicaRes/

comment:4 by Francesco Casella, 5 years ago

Milestone: 1.14.01.16.0

Releasing 1.14.0 which is stable and has many improvements w.r.t. 1.13.2. This issue is rescheduled to 1.16.0

comment:5 by Francesco Casella, 4 years ago

Milestone: 1.16.01.17.0

Retargeted to 1.17.0 after 1.16.0 release

comment:6 by Francesco Casella, 4 years ago

Milestone: 1.17.01.18.0

Retargeted to 1.18.0 because of 1.17.0 timed release.

comment:7 by Francesco Casella, 3 years ago

Milestone: 1.18.0

Ticket retargeted after milestone closed

Note: See TracTickets for help on using tickets.