Opened 4 years ago

Closed 4 years ago

Last modified 4 years ago

#6231 closed defect (fixed)

NF with positiveMax in connections of arrays of port

Reported by: Francesco Casella Owned by: Per Östlund
Priority: high Milestone: 1.17.0
Component: New Instantiation Version: 1.16.0
Keywords: Cc: Andrea Bartolini

Description

Please consider the attached MWE. When trying to run model M, the NF complains that

[1] 13:13:25 Translation Error
[OMCompiler/Compiler/NFFrontEnd/NFCeval.mo: 1064:9-1064:67]:
Internal error NFCeval.evalBinaryMul failed to evaluate 
‘1e-07 * {1.0, 2.0, 3.0}‘

If you remove the evaluate annotation, and flatten the model, the reason of this issue is clear from all the expressions like

$OMC$PositiveMax(-c[2].v.p.f, 1e-07 * c.v.fnom)

where the first term is a scalar, but the second is (still) an array. This should be

$OMC$PositiveMax(-c[2].v.p.f, 1e-07 * c.v.fnom[2])

Attachments (1)

TestPositiveMaxArray.mo (1.1 KB ) - added by Francesco Casella 4 years ago.

Download all attachments as: .zip

Change History (4)

by Francesco Casella, 4 years ago

Attachment: TestPositiveMaxArray.mo added

comment:1 by Francesco Casella, 4 years ago

Cc: Andrea Bartolini added

comment:2 by Andrea Bartolini, 4 years ago

Resolution: fixed
Status: newclosed

comment:3 by Andrea Bartolini, 4 years ago

Thanks a lot Per for very quickly fix

Note: See TracTickets for help on using tickets.