Opened 4 years ago
Last modified 3 years ago
#6053 new defect
Issue with ASCC and state selection in HanserModelica
Reported by: | Francesco Casella | Owned by: | Karim Adbdelhak |
---|---|---|---|
Priority: | blocker | Milestone: | 1.19.0 |
Component: | Backend | Version: | |
Keywords: | Cc: | dr.christiankral@… |
Description
Please check HanserModelica.SynchronousMachines.SMEE_ShortCircuit2. The backend processing fails at some point because of singular linear equations / circular equalities. I suspect the ASCC algorithm may be involved, since the system contains an induction motor with the usual three-phase inductors current constraint.
More specifically, -d=bltdump
reports a fixed state selection
1: smee.phiMechanical:STATE(1,smee.wMechanical)(start = -(3.141592653589793 + gamma0) / /*Real*/(smee.p) unit = "rad" fixed = true ) "Mechanical angle of rotor against stator"HanserModelica.SynchronousMachines.SMEE_ShortCircuit2, Modelica.Magnetic.FundamentalWave.BasicMachines.SynchronousInductionMachines.SM_ElectricalExcited type: Real 2: smee.excitation.electroMagneticConverter.Phi.re:STATE(1)(unit = "Wb" ) "Real part of complex number"HanserModelica.SynchronousMachines.SMEE_ShortCircuit2, Modelica.Magnetic.FundamentalWave.BasicMachines.SynchronousInductionMachines.SM_ElectricalExcited, Modelica.Magnetic.FundamentalWave.BasicMachines.Components.SinglePhaseWinding, Modelica.Magnetic.FundamentalWave.Components.SinglePhaseElectroMagneticConverter, Modelica.SIunits.ComplexMagneticFlux type: Real 3: smee.stator.core.Phi.im:STATE(1)(unit = "Wb" ) "Imaginary part of complex number"HanserModelica.SynchronousMachines.SMEE_ShortCircuit2, Modelica.Magnetic.FundamentalWave.BasicMachines.SynchronousInductionMachines.SM_ElectricalExcited, Modelica.Magnetic.FundamentalWave.BasicMachines.Components.SymmetricMultiPhaseWinding, Modelica.Magnetic.FundamentalWave.Components.EddyCurrent, Modelica.SIunits.ComplexMagneticFlux type: Real 4: smee.stator.core.Phi.re:STATE(1)(unit = "Wb" ) "Real part of complex number"HanserModelica.SynchronousMachines.SMEE_ShortCircuit2, Modelica.Magnetic.FundamentalWave.BasicMachines.SynchronousInductionMachines.SM_ElectricalExcited, Modelica.Magnetic.FundamentalWave.BasicMachines.Components.SymmetricMultiPhaseWinding, Modelica.Magnetic.FundamentalWave.Components.EddyCurrent, Modelica.SIunits.ComplexMagneticFlux type: Real 5: smee.stator.zeroInductor.i0:STATE(1)(unit = "A" ) HanserModelica.SynchronousMachines.SMEE_ShortCircuit2, Modelica.Magnetic.FundamentalWave.BasicMachines.SynchronousInductionMachines.SM_ElectricalExcited, Modelica.Magnetic.FundamentalWave.BasicMachines.Components.SymmetricMultiPhaseWinding, Modelica.Electrical.MultiPhase.Basic.ZeroInductor type: Real
and immediatly afterwards reports a singularity
[3] 16:47:38 Symbolic Warning The linear system: 1 : smee.is[2] = -smee.is[1] 2 : 3.0 * smee.stator.zeroInductor.i0 = smee.is[1] + smee.is[2] + smee.is[3] [ 1.0 , 1.0 ; -1.0 , -1.0 ] * [ smee.is[2] ; smee.is[1] ] = [ 0.0 ; smee.is[3] + (-3.0) * smee.stator.zeroInductor.i0 ] might be structurally or numerically singular for variable smee.is[1] since U(2,2) = 0.0. It might be hard to solve. Compilation continues anyway.
I am pretty sure smee.stator.zeroInductor.i0
shouldn't be a state, maybe @christiankral can comment on that.
For your reference, Dymola selects a fixed state and four dynamically selected states
Statically selected continuous time states constantSpeed.phi Dynamically selected continuous time states There is one set of dynamic state selection. There are 4 states to be selected from: smee.excitation.electroMagneticConverter.Phi.re smee.is[1] smee.rotorCage.electroMagneticConverter.singlePhaseElectroMagneticConverter[1].Phi.re smee.rotorCage.electroMagneticConverter.singlePhaseElectroMagneticConverter[2].Phi.im smee.stator.electroMagneticConverter.singlePhaseElectroMagneticConverter[1].Phi.re smee.stator.electroMagneticConverter.singlePhaseElectroMagneticConverter[2].Phi.im
Attachments (2)
Change History (9)
comment:1 by , 4 years ago
by , 4 years ago
Attachment: | SMEE_ShortCircuit2Ground.png added |
---|
Duplicate of SMEE_ShortCircuit2 with ground connection
by , 4 years ago
Attachment: | SMEE_ShortCircuit2Ground.mo added |
---|
Duplicate of SMEE_ShortCircuit2 with ground connection
follow-up: 3 comment:2 by , 4 years ago
Very often OM fails when three-phase systems are involved.
Maybe it is of help knowing that considering the two models from the PhotoVoltaics library: Examples.SimpleModuleMP and Examples.SimpleModuleMP3, the first one runs correctly, the second hangs.
The second one is very much the same as the first: the only difference is that in the second case a three-phase AC line is involved.
comment:3 by , 4 years ago
Replying to ceraolo:
Very often OM fails when three-phase systems are involved.
The reason for that is that there are implicit constraints among the three phase currents (which are potential state variables due to phase inductances) that make the system index 2. They need to be made explicit in order to reduce the system to index 1 via Pantelides' algorithm. The ASCC algorithm is meant to reveal these hidden constraints, but it doesn't always manage to do that.
Maybe it is of help knowing that considering the two models from the PhotoVoltaics library: Examples.SimpleModuleMP and Examples.SimpleModuleMP3, the first one runs correctly, the second hangs.
Having more examples of failing cases helps a lot to improve the algorithm, thanks!
comment:4 by , 4 years ago
It's interesting to see that the entire HanserModelica library works perfectly fine with the older OMC 1.13.2.
The model
HanserModelica.SynchronousMachines.SMEE_ShortCircuit2
fails with the new frontend.When I create a duplicate model
HanserModelica.SynchronousMachines.SMEE_ShortCircuit2Ground
and add a connection of the two phase short circuit to the "ground", the simulation works with the new front end.In this case OpenModelica shows:
Dymola shows:
For the duplicated and modified model, in OpenModelica and Dymola the variable
smee.stator.zeroInductor.i0
is (dynamically) selected as state.