Opened 7 years ago

Closed 6 years ago

#4969 closed defect (fixed)

Issue with NFCeval.evalBinarySub

Reported by: Francesco Casella Owned by: Adrian Pop
Priority: high Milestone: 2.0.0
Component: New Instantiation Version:
Keywords: Cc:

Description

Please check ThermoPower.Examples.HRB.Simulators.ClosedLoopDigitalSimulator. The following error is reported:

[Compiler/NFFrontEnd/NFCeval.mo:559:9-559:67:writable] Error: 
Internal error NFCeval.evalBinarySub failed to evaluate ‘j - 1‘

The error is so bad that even the encoding of the stuff which cannot be evaluated is wrong...

Change History (8)

comment:1 by Martin Sjölund, 7 years ago

The error is so bad that even the encoding of the stuff which cannot be evaluated is wrong...

I fixed the server to return encoding=utf8 for .err and .sim files. It just says:

‘j - 1‘

(using utf8 pretty quotes)

Last edited 7 years ago by Martin Sjölund (previous) (diff)

comment:2 by Per Östlund, 7 years ago

Resolution: fixed
Status: newclosed

Fixed in 82c686da. The model now seemingly fails due to #4968 instead.

comment:3 by Francesco Casella, 6 years ago

Resolution: fixed
Status: closedreopened

Another failure case here: Modelica.Magnetic.QuasiStatic.FundamentalWave.Examples.BasicMachines.InductionMachines.IMC_Characteristics:

[OMCompiler/Compiler/NFFrontEnd/NFCeval.mo:752:9-752:67:writable]
Error: Internal error NFCeval.evalBinarySub failed to evaluate k - 1

comment:4 by Per Östlund, 6 years ago

Owner: changed from Per Östlund to Adrian Pop
Status: reopenedassigned

The issue is that we try to generate equality constraint equations during the typing, before for-loops have been unrolled. And as part of that we try to evaluate the subscripts used in connect equations, which in the case of the FundamentalWave models include iterators that can't be evaluated at that stage.

comment:5 by Francesco Casella, 6 years ago

Resolution: fixed
Status: assignedclosed

This particular problem is now solved, the model fails for other reasons, possibly related to #5163

comment:6 by Francesco Casella, 6 years ago

Resolution: fixed
Status: closedreopened

comment:7 by Francesco Casella, 6 years ago

As well as 16 models in Modelica.Magnetic.QuasiStatic.FundamentalWave.Examples.BasicMachines

comment:8 by Per Östlund, 6 years ago

Resolution: fixed
Status: reopenedclosed

This was fixed some time ago, all the QuasiStatic models now seem to work as well as with the old frontend.

Note: See TracTickets for help on using tickets.