Opened 10 years ago

Closed 5 years ago

Last modified 5 years ago

#2996 closed defect (fixed)

This very simple circuit fails

Reported by: massimo ceraolo Owned by: Karim Adbdelhak
Priority: normal Milestone: Future
Component: Backend Version: trunk
Keywords: Cc:

Description (last modified by massimo ceraolo)

I came across in a circuit that fails to simulate with OM r23316.
I've simplified it as much as possible.
The final version, that I enclose (test.mo), contains a very few components and does not simulate.
It should be ok and simulates well in Dymola.
Any further simplification produces a circuit that OM can simulate.

Since it is rather simple, maybe by analysing this it is possible to find some OM weakness that can be fixed.

Error message:

[:0:0-0:0] Error: Internal error Transformation Module sort components failed!
[c:/dev/OpenModelica/Compiler/BackEnd/BackendDAETransform.mo:114:7-115:62] Error: Internal error function strongComponentsScalar failed

  • sorting equations (strongComponents) failed

[c:/dev/OpenModelica/Compiler/BackEnd/BackendDAETransform.mo:468:9-468:92] Error: Internal error function analyseStrongComponentBlock failed
[:0:0-0:0] Error: When solving linear system
1 : (-Lf2.i) - rDn.i - dcCap.i = 0.0
2 : rDn.i + Lf.i - rUp.i = 0.0
3 : dcCap.i + rUp.i - Lf1.i = 0.0
[

-1.0 , 0.0 , -1.0 ;
0.0 , -1.0 , 1.0 ;
1.0 , 1.0 , 0.0

]

*

[

dcCap.i ;
rUp.i ;
rDn.i

]

=

[

Lf2.i ;
-Lf.i ;
Lf1.i

]

U(3,3) = 0.0, which means system is singular for variable rDn.i.

Attachments (1)

test.mo (3.4 KB ) - added by massimo ceraolo 10 years ago.

Download all attachments as: .zip

Change History (14)

by massimo ceraolo, 10 years ago

Attachment: test.mo added

comment:1 by massimo ceraolo, 10 years ago

Description: modified (diff)

comment:2 by Martin Sjölund, 10 years ago

Given that linear system, you can add Lf2.i+Lf.i+Lf1.i=0, remove either of the equations and re-sort+match. The problem is all of these variables are state variables and can not be solved there :( I guess someone who knows the back-end can figure it out. I assume it works in Dymola?

comment:3 by massimo ceraolo, 10 years ago

yes, it works in Dymola.

Last edited 10 years ago by massimo ceraolo (previous) (diff)

comment:4 by Lennart Ochel, 10 years ago

Owner: changed from somebody to Willi Braun
Status: newassigned

Willi, can you have a look?

comment:5 by Francesco Casella, 6 years ago

Owner: changed from Willi Braun to Karim Adbdelhak

comment:6 by massimo ceraolo, 5 years ago

Resolution: fixed
Status: assignedclosed

This model now works. Must have been solved in the meanwhile.

comment:7 by Francesco Casella, 5 years ago

Great, one less open issue :)

comment:8 by Karim Adbdelhak, 5 years ago

I guess this is due to ASSC :) looks like an analytical singularity to me.

in reply to:  8 ; comment:9 by massimo ceraolo, 5 years ago

Replying to Karim.Abdelhak:

I guess this is due to ASSC ?

pure curiosity on this acronym.

in reply to:  9 comment:10 by Karim Adbdelhak, 5 years ago

Replying to ceraolo:

Replying to Karim.Abdelhak:

I guess this is due to ASSC ?

pure curiosity on this acronym.

Ah sorry, an algorithm that recently got implemented. Analytical to Structural Singularity Conversion.

comment:11 by Francesco Casella, 5 years ago

Since there is no current going into the ground, the two inductors are effectively series connected. However, there is no explicit equation stating that Lf1.i = -LF2.i. So, index reduction is not triggered and you end up with a singular system.

The ASSC algorithm figures out this equation and allows index reduction and successful simulation.

See the (long) discussion in #5452.

in reply to:  11 ; comment:12 by massimo ceraolo, 5 years ago

Replying to casella:

Since there is no current going into the ground

there is some current flowing into the ground

in reply to:  12 comment:13 by Francesco Casella, 5 years ago

Replying to ceraolo:

Replying to casella:

Since there is no current going into the ground

there is some current flowing into the ground

Of course, sorry about that! I thought there was only one ground component, obviously if there are two of them there is a ground loop, hence the current flowing into ground is the same that flows out of ground1.

This means that a constraint equation

Lf.i = Lf1.i + Lf2.i

holds between the three potential states of the inductors. Hence, index reduction is needed, but the tool need to figure out this constraint equation from the system equations.

Note: See TracTickets for help on using tickets.