Hi Marc,
The problem seems to be that OMC usually stops expanding arrays when
their dimensions exceeds 20, and the code generator seems to be having
some problems with the non-expanded array assignment. This is of course
a bug, and we will try and fix it.
If you can compile OMC yourself you can try the latest version from SVN,
where I have added a new flag +v to OMC that you can use to set the
array expansion limit yourself.
Best regards,
Per Östlund
On 2010-08-11 16:42, Dierckx Marc wrote:
Hello,
I seem to have problems with larger arrays. The following model won't
run in OMshell. It gives the error: Error building simulator.
Buildlog: command g++ not found. Check $OPENMODELICAHOME ...
model md1
Real T[30](start=ones(30)*200);
Real Tin=100;
Real temp[30](start=zeros(30));
equation
temp[1]=100.0;
temp[2:30]=T[2:30];
der(T)=temp;
end md1;
The strange thing is that arrays up to a length of 20 seem to work
just fine ... as soon as the array increases above 20 I get this error.
Flattening of the model seems not to be any problem ... the problem is
in the compilation of the code ... please help !
Kind regards,
Marc Dierckx
SCK•CEN
SCK?CEN Disclaimer: www.sckcen.be/en/Legal-aspects/E-mail-disclaimer