Skip to content

Commit

Permalink
Modified LSQR, CRAIG and CRAIGMR for damping factor settings.
Browse files Browse the repository at this point in the history
  • Loading branch information
syarra authored and dpo committed Oct 5, 2015
1 parent f4fdad8 commit bcb4046
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 10 deletions.
5 changes: 1 addition & 4 deletions pykrylov/lls/craig.py
Expand Up @@ -180,10 +180,7 @@ def solve(self, rhs, itnlim=0, damp=0.0, M=None, N=None, atol=1.0e-9,
else:
var = None

if N is not None:
damp = dampsq = 1.0
else:
dampsq = damp*damp;
dampsq = damp*damp;

itn = istop = 0
ctol = 0.0
Expand Down
2 changes: 0 additions & 2 deletions pykrylov/lls/craigmr.py
Expand Up @@ -70,8 +70,6 @@ def solve(self, b, damp=0.0, atol=1e-9, btol=1e-9, conlim=1e8,

if itnlim is None: itnlim = minDim

if N is not None: damp = 1.0

# Initialize the Golub-Kahan bidiagonalization process.

Mu = b.copy() # Don't want to change input vector.
Expand Down
5 changes: 1 addition & 4 deletions pykrylov/lls/lsqr.py
Expand Up @@ -156,10 +156,7 @@ def solve(self, rhs, itnlim=0, damp=0.0, M=None, N=None, atol=1.0e-9,
else:
var = None

if N is not None:
damp = dampsq = 1.0
else:
dampsq = damp*damp;
dampsq = damp*damp;

itn = istop = 0
ctol = 0.0
Expand Down

0 comments on commit bcb4046

Please sign in to comment.