-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use gauss_elimination_interval to solve A*b = x in contractors #111
base: master
Are you sure you want to change the base?
Conversation
Codecov Report
@@ Coverage Diff @@
## master #111 +/- ##
==========================================
+ Coverage 58.48% 59.12% +0.63%
==========================================
Files 11 11
Lines 542 526 -16
==========================================
- Hits 317 311 -6
+ Misses 225 215 -10
Continue to review full report at Codecov.
|
end | ||
inv_diagA = inv(diagA) | ||
inv_diagA = 1 ./ diagA | ||
|
||
for iter in 1:maxiter |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe there should be a more sophisticated convergence check here that checks some kind of rate of convergence?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The reference given (Eldon Hansen and G. William Walster : Global Optimization Using Interval Analysis - Chapter 5 - Page 115) does only state the process can be iterated until no changes happen. I'll have to dig a bit more in the litterature to see if something more subtle exist.
Reading the litterature in more detail may also indicate if Gauss elimination is the best choice as default linear equation solver.
From what I've read, it's recommended to use interval Gauss-Seidel. Probably we should change |
Or is that what's already being done? |
Sorry this fell off the radar; it looks very nice. @Kolaru Are you able to come back to this or should I try to? |
I tried to rebase or merge, but the conflicts come from #153 with which I'm not familiar, making it hard. So if you still have the changes in mind you may have more luck than me. Otherwise I'll take a deeper look, probably next week. |
This PR forces the used of (preconditionned) Gauss elimination in Newton contractor.
It required some adjustement as the previous definition of the algorithm for
SArray
was incorrect. In order to stay simple, this PR drops support for vector and matrices that are neitherMArray
orSArray
The change result in small perfomance improvements. Unfortunately not enough to test the functions mentionned in #108 and #86 in a reasonnable amount of time, but it is a first step towards solving these issues.
Other changes:
SArray
rather thantArray
.gauss_seidel_contractor
had to be modified to handleSArray
efficiently.And finally here is the benchmark report. Note that the improvements concerning the functions in
linear_eq.jl
do not give much information as the benchmarks where modified.Benchmark report
Benchmark Report for IntervalRootFinding
Job Properties
Results
A ratio greater than
1.0
denotes a possible regression (marked with ❌), while a ratio lessthan
1.0
denotes a possible improvement (marked with ✅). Only significant results - resultsthat indicate possible regressions or improvements - are shown below (thus, an empty table means that all
benchmark results remained invariant between builds).
["Dietmar-Ratz", "Dietmar-Ratz 9", "Krawczyk"]
["Linear equations", "n = 10", "Gauss elimination"]
["Linear equations", "n = 10", "Gauss seidel contractor"]
["Linear equations", "n = 10", "Gauss seidel"]
["Linear equations", "n = 2", "Gauss elimination"]
["Linear equations", "n = 2", "Gauss seidel contractor"]
["Linear equations", "n = 2", "Gauss seidel"]
["Linear equations", "n = 5", "Gauss elimination"]
["Linear equations", "n = 5", "Gauss seidel contractor"]
["Linear equations", "n = 5", "Gauss seidel"]
["Rastigrin stationary points", "Newton"]
["Smiley", "Smiley and Chun (2001), Example 2.2", "Newton"]
["Smiley", "Smiley and Chun (2001), Example 5.2", "Newton"]
["Smiley", "Smiley and Chun (2001), Example 5.4", "Newton"]
Benchmark Group List
Here's a list of all the benchmark groups executed by this job:
["Dietmar-Ratz", "Dietmar-Ratz 1"]
["Dietmar-Ratz", "Dietmar-Ratz 2"]
["Dietmar-Ratz", "Dietmar-Ratz 3"]
["Dietmar-Ratz", "Dietmar-Ratz 4"]
["Dietmar-Ratz", "Dietmar-Ratz 5"]
["Dietmar-Ratz", "Dietmar-Ratz 6"]
["Dietmar-Ratz", "Dietmar-Ratz 7"]
["Dietmar-Ratz", "Dietmar-Ratz 8"]
["Dietmar-Ratz", "Dietmar-Ratz 9"]
["Linear equations", "n = 10"]
["Linear equations", "n = 2"]
["Linear equations", "n = 5"]
["Rastigrin stationary points"]
["Smiley", "Smiley and Chun (2001), Example 2.2"]
["Smiley", "Smiley and Chun (2001), Example 5.2"]
["Smiley", "Smiley and Chun (2001), Example 5.4"]
Julia versioninfo
Target
Baseline