Opened 10 years ago
Closed 10 years ago
#2841 closed defect (fixed)
Nominal values of iteration variables in non-linear system solvers
Reported by: | Lennart Ochel | Owned by: | Lennart Ochel |
---|---|---|---|
Priority: | high | Milestone: | 1.9.1 |
Component: | Run-time | Version: | trunk |
Keywords: | Cc: | Adrian Pop, Willi Braun |
Description (last modified by )
The solvers for linear, non-linear and mixed systems are working on wrong variable attributes, e.g. nominal values. This can be investigated using the following model:
model problem10 parameter Real xn = 1e5; parameter Real yn = 1e-5; Real x(start=1.5*xn, nominal=xn); Real y(start=1.5*yn, nominal=yn); equation 0 = -(x/xn)*exp(-(x/xn)*(y/yn))-1; 0 = (y/yn)*exp(-(x/xn)+(y/yn))-1; end problem10;
The issue is, that the attributes get copied for the solvers before the parameters are calculated. I already worked out a patch that fixes this problem. Unfortunately, there are models that need to solve non-linear systems (by defect) to evaluate parameters, see #1651. Because cyclic dependencies in parameter bindings is not allowed, that ticket should get fixed first.
Change History (8)
comment:1 by , 10 years ago
Description: | modified (diff) |
---|
comment:2 by , 10 years ago
Cc: | added |
---|
follow-up: 4 comment:3 by , 10 years ago
follow-up: 6 comment:4 by , 10 years ago
Replying to sjoelund.se:
Note that cyclic dependencies in parameter equations is allowed in initial equations. Since NLS are allowed, it should be possible to create the nominal attributes on the fly however.
As far as I know it is not allowed to use parameters with fixed=false as, e.g., nominal attribute. Is that what you mean? Can you please given an example?
comment:5 by , 10 years ago
Status: | new → accepted |
---|---|
Summary: | Nominal values of iteration variables in linear/non-linear/mixed system solvers → Nominal values of iteration variables in non-linear system solvers |
BTW: this is only about non-linear systems.
comment:6 by , 10 years ago
Replying to lochel:
As far as I know it is not allowed to use parameters with fixed=false as, e.g., nominal attribute. Is that what you mean? Can you please given an example?
No, it was just a general comment that parameters need to be able to solve NLS.
comment:7 by , 10 years ago
Yes, but that is only true for parameters with fixed=false, right? This is about parameter with binding expressions and those have to be acyclic.
Note that cyclic dependencies in parameter equations is allowed in initial equations. Since NLS are allowed, it should be possible to create the nominal attributes on the fly however.