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

Ramp overshoots

Ramp overshoots

I've made a simulation where I use blocks.sources.ramp to open a valve (go from 0-1) the problem is that the ramp does not stop at 1 as expected. It keeps going until the simulation crashes. Any idea what I'm done wrong?

Code:


Modelica.Blocks.Sources.Ramp ramp(duration = 6, height = 1, offset = 0, startTime = 30)

Between the valve and ramp I’ve inserted a gain(k=1) since there is some strange bug if this is not there. The error I get without the gain:

Code:

[1] 14:47:20 Symbolic Warning

The model contains alias variables with redundant start and/or conflicting nominal values. It is recommended to resolve the conflicts, because otherwise the system could be hard to solve. To print the conflicting alias sets and the chosen candidates please use -d=aliasConflicts.

[2] 14:47:20 Translation Error
Jacobian StateSetJac28 contains non-linear components. This indicates a singular system or internal generation errors.

[3] 14:47:20 Translation Warning
Assuming fixed start value for the following 2 variables:
         tank.medium.T:VARIABLE(min = max(1.0, max(1.0, 1.0)) max = min(10000.0, min(10000.0, 10000.0)) start = tank.T_start unit = "K" fixed = true nominal = 300.0 stateSelect=StateSelect.prefer )  "Temperature of medium"test, Modelica.Fluid.Vessels.OpenTank, tank.Medium.BaseProperties type: Real
         $STATESET1.x[1]:VARIABLE(start = /*Real*/($STATESET1.A[1,1]) * $START.tank.level + /*Real*/($STATESET1.A[1,2]) * $START.pump.medium.p + /*Real*/($STATESET1.A[1,3]) * $START.pump.s + /*Real*/($STATESET1.A[1,4]) * $START.firstOrder.y fixed = true )  type: Real [2]

[4] 14:47:20 Translation Error
Jacobian StateSetJac36 contains non-linear components. This indicates a singular system or internal generation errors.

[5] 14:47:20 Translation Error
[C:/OM116/OM64bit/OMCompiler/Compiler/SimCode/SimCodeUtil.mo: 4493:9-4493:59]: Internal error function createStateSetsSets failed.

[6] 14:47:20 Translation Error
[C:/OM116/OM64bit/OMCompiler/Compiler/SimCode/SimCodeUtil.mo: 748:5-748:146]: Internal error function createSimCode failed [Transformation from optimised DAE to simulation code structure failed]

Any idea?

Edited by: victor - Nov-02-20 14:43:30
There are 0 guests and 0 other users also viewing this topic