Closed Mathadon closed 9 years ago
@Mathadon
This is a good improvement. I verified that your solution works, made a branch (issue227_inline
) and added Inline=true
for temperature_phX
and specificEnthalpy_pTX
.
I am quite sure that there are other such cases. It would be good if you can look at the library and issue a pull request.
I'll have a look at it, possibly after the BS2015 deadline.
@Mathadon :
I added Inline=true
to all media functions.
Consider the following example:
When using
Annex60.Media.Water
Dymola detects a linear system of equations but this can be solved analytically, resulting in:However, when using
Annex60.Media.Air
we get:Dsmodel.mof contains the following system:
the problem seems to be that there is a
function
in this algorithm:temperature_phX_Unique4
due to this function Dymola is unable to exploit the (linear) problem structure. This can be solved by settingInline=true
inAnnex60.Media.Air.temperature_phX
:We should probably identify other functions where inlining may be advantageous.