Archived OpenModelica forums. Posting is disabled.

Alternative forums include GitHub discussions or StackOverflow (make sure to read the Stack Overflow rules; you need to have well-formed questions)


Forgot password? | Forgot username? | Register

Debugging errors SolarTherm library

Debugging errors SolarTherm library

Hello,

I need help debugging my STv1 file (attached). I am using the SolarTherm library, which is from version 3.2.2, and I am using version 3.2.3. If you go to Tools -> Options -> Libraries, you can change to version 3.2.3, and you can load SolarTherm by going to File -> System Libraries -> SolarTherm. I have a few questions about my STv1 file. Any help with any of the questions would be greatly appreciated.
STv1.mo


1. What are "A$" units exactly?
2. Do units matter if the value is 0?
3. Why is it when I check the model I have 186 variables, but when I simulate it I have 206 variables?
4. Is there a way to circumvent my error with Medium being a partial class?
5. Why do my variables P_elec and CL.oeff.eff have no remaining equations to be solved in?
6. Will a pure function calling an impure function cause any issues?
7. Will using a conditional component in a non-connect context cause any issues?
8. What could be causing " Internal error function lexer failed"?
9. Why is my the unit check module failing?
ScottWeatherSource.mo

Edited by: scoia - Jul-31-21 18:53:13

Re: Debugging errors SolarTherm library

Hi,
Some of the problems you are having are related to the non-standard construction of the SolarTherm library. For example the problem you had with connections, and now the problem with assigning units to Integer variables. According to the Modelica specification the Integer type has no "unit" attribute, but SolarTherm is using it. You have two options: one is to delete the the unit assignament for the Integer variables, the second is to use the old frontend of OpenModelica, that is much more permissive with this type of non-standard syntax.
Regarding the number of equations and variables, I have found many times this disagreement and in my experience the correct value is the one you obtain when running the model. The identification of the Medium as partial class is clearly a fail of the OpenModelica new frontend, and the problem dissapears with the old one. It seems that 3 equations are missing. As I have no knowledge about SolarTherm I can say nothing more.

Carlos

There are 0 guests and 0 other users also viewing this topic
You are here: