Opened 7 years ago
Last modified 7 years ago
#4864 closed defect
The NF does not expand the sum() function — at Initial Version
Reported by: | Francesco Casella | Owned by: | Per Östlund |
---|---|---|---|
Priority: | high | Milestone: | 2.0.0 |
Component: | New Instantiation | Version: | |
Keywords: | Cc: |
Description
Please check the ScalableTestSuite.Thermal.HeatExchanger.ScaledExperiments.CocurrentHeatExchangerEquations_N_10 model. It fails at link time due to the lack of definition of the sum_metatype_array
type.
The NF flattens this equation
QtotA = sum(QA);
while the old FE gives
QtotA = QA[1] + QA[2] + QA[3] + QA[4] + QA[5] + QA[6] + QA[7] + QA[8] + QA[9];
As i #4863 I'm not sure if we should expand the array when the DAE structure is created, or rather extend the code generation to handle the sum function explicitly.
If expanding the array in the NF is easily accomplished, I would suggest to do that, at least for the time being, so we can get the maximum coverage without waiting for somebody to fix the code generation.