-
Notifications
You must be signed in to change notification settings - Fork 480
comments fixed: op missed #562
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
Conversation
Codecov Report
@@ Coverage Diff @@
## master #562 +/- ##
=======================================
Coverage 82.37% 82.37%
=======================================
Files 1894 1894
Lines 190677 190677
=======================================
Hits 157063 157063
Misses 33614 33614 Continue to review full report at Codecov.
|
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.
Good catch. Thanks @jip. I agree. op(A), not A. You are correct.
Well, then I ended up reading this routine. LOL.
One comments then.
I thought it would be good to state the norm used by the routine in the comments. I read:
CQRT17 computes the ratio
|| R^H * op(A) || / ( ||A|| * alpha * max(M,N,NRHS) * eps )
where R = op(A) * X - B, op(A) is A or A^H, and
alpha = || B || if IRESID = 1 (zero-residual problem)
alpha = || R || if IRESID = 2 (otherwise).Great. Which norm?
Then I see that the code uses the 1-norm.
Then this line caught my eyes:
NORMA = CLANGE( 'One-norm', M, N, A, LDA, RWORK )And then I was not sure whether we should take the 1-norm of A or the 1-norm of op(A).
If we add "all norms are 1-norm" then the comments and code would be correct. (They already were, but that's just to clarify.) And that would be that.
Although I am not sure whether we should take the 1-norm of A or the 1-norm of op(A) in this context.
Oh well. The code takes the 1-norm of A, that’s fine with me.
( If we want the 1-norm of op(A), we can simply take the Inf-norm of A and that’ll do the trick. )
|
Routines xGTT02, xTBT02, xTPT02, xTRT02 use 1-norm of op(A). Since norm(A) == norm(op(A)) for PB, PO, PP, PT, SP and SY cases, the same is true for xPBT02, xPOT02, xPPT02, xPTT02, xSPT02 and xSYT02 routines, too. So it may be seen that xxxT02 testing routines excepting xGBT02 and xGET02 use 1-norm of op(A) not just A. This contradicts with approach in xQRT17 which uses 1-norm of A not op(A). xGBT02 and xGET02 routines use 1-norm of A. I could make a PR to arrange this but not sure it's an error. By the way, comments in xGTT02 declare that it uses norm(A) but its code implements 1-norm of op(A). |
|
Hi @jip. Thanks for clarifying. "Error" is a big word. Maybe it’s a "feature"! :). In any case, I think we want (a) to have correct comments (so the comments should say norm(op(A)) when we use norm(op(A))), (b) to have more comments (specify the norm used), (c) be consistent (so compute op(A) for all these testings subroutines.)
|
|
Yes, I do. I'll prepare 3 separate PRs. |
comments fixed: op missed
…eference-LAPACK#562) 1. Comments improved, unified and fixed. 2. Code changed. To unify with routines xGTT02, xTBT02, xTPT02, and xTRT02.
…eference-LAPACK#562) 1. Comments improved, unified and fixed. 2. Code changed. To unify with routines xGBT01, xGTT02, xTBT02, xTPT02, and xTRT02.
modify xGBT02 and xGET02 to use 1-norm of op(A) not A (no.2 from PR #562)
…PACK#562) Despite the recommendation, no change has been made in xGBT02, xGET02, xGTT02, xTBT02, xTPT02, and xTRT02 for C,Z datatypes yet: as it was noted afterwards in PR Reference-LAPACK#571, those routines are using mixed types of norm: 1-norm for op(A) and taxicab-based norm |Re(z)|+|Im(z)| for residual.
fixed comments: specify which norm is used (no.1 from PR #562)
Error in xQRT17 comments fixed.