Opened 5 years ago
Closed 4 years ago
#3878 closed enhancement (fixed)
Improve support for handling singular Jacobians in kinsol
Reported by: | Christian Andersson | Owned by: | Christian Andersson |
---|---|---|---|
Priority: | major | Milestone: | 1.17.x |
Component: | FMU/JMU runtime | Version: | trunk |
Keywords: | #4391. | Cc: |
Description (last modified by )
We should improve our regularization strategy for when a singular Jacobian is detected. The improvement consists of being able to choose between performing a regularization and calculating the minimum norm solution.
Interesting model that needs this:
Modelica.Fluid.Examples.Tanks.TanksWithOverflow
Attachments (3)
Change History (18)
Changed 5 years ago by
Attachment: | kinsol_min_norm.patch added |
---|
comment:1 Changed 5 years ago by
comment:2 Changed 5 years ago by
Milestone: | → 1.15.x |
---|
Changed 5 years ago by
Attachment: | kinsol_min_norm_v2.patch added |
---|
comment:3 Changed 5 years ago by
Milestone: | 1.15.x → 1.16.x |
---|
Changed 5 years ago by
Attachment: | kinsol_min_norm_v3.patch added |
---|
comment:4 Changed 5 years ago by
Description: | modified (diff) |
---|---|
Keywords: | #3878 added |
comment:5 Changed 5 years ago by
Keywords: | #3878. added; #3878 removed |
---|
comment:6 Changed 5 years ago by
Keywords: | #4391 added; #3878. removed |
---|
comment:7 Changed 5 years ago by
Keywords: | #4391. added; #4391 removed |
---|
comment:8 Changed 5 years ago by
Added patch v3 that does not have any merge conflicts. Observe that the condition number check is for 10e10 which is not a very good choice. This does however result in that the model Modelica.Fluid.Examples.Tanks.TanksWithOverflow simulates.
What we need is to see if the problem is singular in the current point or if the problem is structurally singular for the current state the problem is in. A suggestion would be to check if the problem is repeatedly singular then this is a hint for using minimum norm rather than regularization.
comment:9 Changed 5 years ago by
Another idea would be to use minimum norm as default and after a solution is obtained check that it is consistent (norm(Ax - b) < tol ) and that we are not close to a zero gradient. In case one of these checks fail we will instead do a regularization of the problem and use the solution of it instead.
comment:10 Changed 4 years ago by
Milestone: | 1.16.x → 1.17.x |
---|
comment:11 Changed 4 years ago by
Updated handling of singular Jacobians in Kinsol with using minimum norm solution instead of repeated regularizations (activated using experimental mode 64). Related to ticket:3878
comment:12 Changed 4 years ago by
Testing the approch of using minimum norm together with regularization. Related to ticket:3878
comment:13 Changed 4 years ago by
Reverting the option used in the test made in changeset:8040 related to ticket:3878
comment:14 Changed 4 years ago by
Activated the minimum norm solution in Kinsol for repeated singular Jacobians and added tests. Related to ticket:3878
comment:15 Changed 4 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
This is considered fixed as of changeset:8065 . For improvements see #4600
The patch adds the functionality. What is missing is reusing the information from the SVD performed in the lsetup in lsolve.