﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
4496	Complex 'sum' does not work	Christian Kral <dr.christian.kral@…>	Per Östlund	"Please consider the following example:

{{{
model TestComplexSum
  parameter Complex a[2]={Complex(1,2),Complex(2,3)};
  parameter Complex sum1 = Modelica.ComplexMath.'sum'(a);
  parameter Complex sum2 = Complex(sum(a.re),sum(a.im));
end TestComplexSum;
}}}

The sum of vector {{{a}}} is calculated in two different ways, so the results shall be equal. However, in OpenModelica {{{sum2}}} is calculated correctly, whereas {{{sum1}}} results in

{{{
sum1.re -> 0
sum2.re -> 0
}}}

Too bad: The application of function {{{'sum'}}} is utilized in the actual trunk version of the MSL in order to calculate the the total apparent power in {{{Modelica.Electrical.QuasiStationary.MultiPhase.Sensors.MultiSensor}}}. I would not really like to switch to the alternative calculation of sum1... 

Do you think there is a chance, that this issue is going to be fixed in OpenModelica 1.12? The reason I am asking is that I am planning to refer to OpenModelica in a publication so, so I am not sure if can include a related example or not."	defect	assigned	blocker	2.0.0	New Instantiation				Lennart Ochel Mahder Alemseged Gebremedhin
