Closed nrontsis closed 3 years ago
Merging #244 into master will decrease coverage by
0.18%
. The diff coverage is100%
.
@@ Coverage Diff @@
## master #244 +/- ##
==========================================
- Coverage 90.52% 90.34% -0.19%
==========================================
Files 17 17
Lines 1077 1077
==========================================
- Hits 975 973 -2
- Misses 102 104 +2
Impacted Files | Coverage Δ | |
---|---|---|
src/cg.jl | 90.69% <100%> (-4.66%) |
:arrow_down: |
Continue to review full report at Codecov.
Legend - Click here to learn more
Δ = absolute <relative> (impact)
,ø = not affected
,? = missing data
Powered by Codecov. Last update 17ef261...263dce7. Read the comment docs.
bump!
Bump. That's a good observation! See also #280.
The problem
CG does not respect the stopping criterion of the documentation:
as it can be observed from the following minimal example:
It appears that
cg
stops when|r_k| / |b| ≤ tol
. However, I am unsure if this actually holds, as theCGStateVariables
are filled with vectors generated with thesimilar()
command which can be problematic, as it does not initialise the memory of the vectors.Suggested solution
Change the stopping criterion to match the one of the documentation and replace
similar()
withzero()
.I suppose that another possibility would be to change the documentation? Let me know what you think!