Francesco Casella

Results 1726 comments of Francesco Casella

I checked the model. The flat instantiated model contains: ```modelica Real tube.fluidInlet.h(quantity = "SpecificEnergy", unit = "J/kg", stateSelect = StateSelect.default) = if tube.inlet.m_flow > 0.0 then massFlowSource.steam_a.h_outflow else tube.inlet.h_outflow "Specific...

> The model contains these two equations: > > ```modelica > tube.fluidInlet.h = if tube.inlet.m_flow > 0.0 then massFlowSource.steam_a.h_outflow else tube.inlet.h_outflow; > tube.inlet.h_outflow = tube.fluidInlet.h; // this is explicitly written...

Besides, `tube.inlet.h_outflow = tube.fluidInlet.h` is of course going to be generate a cyclic singularity when the flow becomes negative, because you basically say h_in = h_out and then h_out =...

@perost I see your point, but nevertheless that model seems to me to be 100% legal, so we shouldn't fail during flattening because we over-check it. Can't we check this...

Then I guess the check that implicitly discrete variables are not differentiated should be done by the backend, since the NF check is overly restrictive. @phannebohm what do you think?

@phannebohm this was marked as a regression 10 months ago, it would be nice if we could fix it in 1.21.0. Do you think you can handle that? Thanks!

I confirm the problem is solved, see [regression report](https://libraries.openmodelica.org/branches/history/master/2023-03-21%2011:26:14..2023-03-21%2022:26:19.html). Thanks @phannebohm for the fast action!

@angmarion please note the new backend is still very far from being mature, this will probably take a couple more years.