Skip to content

TESTING: parameters set incorrectly for triangular band matrices in DLATB4 #343

@vladimir-ch

Description

@vladimir-ch

DLATB4 is called from DLATTB with IMAT negative for lower triangular matrices:

      IF( UPPER ) THEN
         CALL DLATB4( PATH, IMAT, N, N, TYPE, KL, KU, ANORM, MODE,
     $                CNDNUM, DIST )
....
      ELSE
         CALL DLATB4( PATH, -IMAT, N, N, TYPE, KL, KU, ANORM, MODE,
     $                CNDNUM, DIST )
...
      END IF

However, DLATB4 does not consider the sign if IMAT for triangular band matrices:

         IF( IMAT.EQ.2 .OR. IMAT.EQ.8 ) THEN
            CNDNUM = BADC1
         ELSE IF( IMAT.EQ.3 .OR. IMAT.EQ.9 ) THEN
            CNDNUM = BADC2
         ELSE
            CNDNUM = TWO
         END IF
*
         IF( IMAT.EQ.4 ) THEN
            ANORM = SMALL
         ELSE IF( IMAT.EQ.5 ) THEN
            ANORM = LARGE
         ELSE
            ANORM = ONE
         END IF

Consequently, lower triangular band matrices are tested only with CNDNUM=2 and ANORM=1. This is in contrast to triangular (packed) matrices in DLATB4 where the corresponding code uses MAT = ABS( IMAT ) instead of IMAT.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions