Opened 10 years ago
Closed 8 years ago
#3762 closed defect (invalid)
OpenModelica simulation hangs for ModelicaTest.Math.Random.TestRandomNumbers
| Reported by: | Owned by: | somebody | |
|---|---|---|---|
| Priority: | normal | Milestone: | NeedsInput |
| Component: | Frontend | Version: | |
| Keywords: | Cc: |
Description
OpenModelica 1.9.4 Beta.2 translates ModelicaTest.Math.Random.TestRandomNumbers from the trunk (March 12). When simulating, there is a warning message that the step-size has to be reduced to 1e-12 and then the simulator "hangs" (the model initializes and has an event at time=0 due to when sample(0,1). I also tried to change to sample(0.1,1), but this did not have an effect).
Change History (7)
comment:1 by , 10 years ago
| Component: | Run-time → Frontend |
|---|
comment:3 by , 10 years ago
I tried with the Windows release OpenModelica v1.9.4-dev.beta2. The current trunk version of the model simulates. The nightly tests also verify the simulation results, see:
https://test.openmodelica.org/libraries/ModelicaTest_trunk/BuildModelRecursive.html
Does the problem still exist for you?
comment:5 by , 9 years ago
| Milestone: | 1.11.0 → 1.12.0 |
|---|
Milestone moved to 1.12.0 due to 1.11.0 already being released.
comment:6 by , 8 years ago
| Milestone: | 1.12.0 → Future |
|---|
The milestone of this ticket has been reassigned to "Future".
If you think the issue is still valid and relevant for you, please select milestone 1.13.0 for back-end, code generation and run-time issues, or 2.0.0 for front-end issues.
If you are aware that the problem is no longer present, please select the milestone corresponding to the version of OMC you used to check that, and set the status to "worksforme".
In both cases, a short informative comment would be welcome.
comment:7 by , 8 years ago
| Milestone: | Future → NeedsInput |
|---|---|
| Resolution: | → invalid |
| Status: | new → closed |

I tried several different versions, but always failed to get it running in OpenModelica. The latest version in the trunk does not translate (maybe because OpenModelica does not support multiple return values of functions, or arrays in multiple return values, if called in a when-clause in an equation section. As I recall, translation is successful, if the when-clause is in an algorithm section):
[1] 10:52:11 Translation Error [ModelicaTest.Math.ScalarFunctions: 1219:9-1219:120]: Invalid left-hand side of when-equation: {state2[1], state2[2]}. // note, the error message points to the wrong Modelica functions. [2] 10:52:11 Translation Error Error occurred while flattening model ModelicaTest.Math.Random.TestRandomNumbers