a little Modelica-programmers question:
I work on a model for a stratified storage for hot water. It exists of n "layers" of water which are instantiated by creating a vector-component layer[n] of the type Layer
CODE
Layer layer[n]
and are connected within the equation area by a for-loop.
CODE
for i in 1 : n-1 loop
connect(layer[i].out, layer[i+1].in);
end for;
connect(layer[i].out, layer[i+1].in);
end for;
The layers have a parameter for their start-temperature. Until now I commit the same start-temperature to all layers by
CODE
Layer layer[n](each T_0=T_0);
But in real life each layer starts with it's own temperature so I would like to commit different start-temperatures to different layers.
Do you have any idea how to do this?
Thank you!
david.