lanhf(3)

๐Ÿ’– lanhf(3) โ€” Library Functions Manual ๐Ÿ’–

okay so welcome to lanhf(3), bestie โ€” this is the Library Functions Manual page for the lan{hf,sf} crew, and itโ€™s all about Hermitian/symmetric matrix RFP norm energy. โœจ


๐ŸŒธ NAME ๐ŸŒธ

lanhf โ€” lan{hf,sf}: Hermitian/symmetric matrix, RFP. Thatโ€™s the whole title, no cap. ๐Ÿ’…


โœจ SYNOPSIS โœจ

๐Ÿ’ซ Functions ๐Ÿ’ซ

  • real function clanhf (norm, transr, uplo, n, a, work) โ€” CLANHF returns the value of the 1-norm, or the Frobenius norm, or the infinity norm, or the element of largest absolute value of a Hermitian matrix in RFP format. ๐Ÿซถ
  • double precision function dlansf (norm, transr, uplo, n, a, work) โ€” DLANSF returns the value of the 1-norm, or the Frobenius norm, or the infinity norm, or the element of largest absolute value of a symmetric matrix in RFP format. ๐Ÿ’–
  • real function slansf (norm, transr, uplo, n, a, work) โ€” SLANSF (yes, the original blurb is literally just the name, and honestly? iconic minimalism ๐Ÿ˜ญ).
  • double precision function zlanhf (norm, transr, uplo, n, a, work) โ€” ZLANHF returns the value of the 1-norm, or the Frobenius norm, or the infinity norm, or the element of largest absolute value of a Hermitian matrix in RFP format. ๐ŸŒŸ

๐Ÿฆ‹ DETAILED DESCRIPTION ๐Ÿฆ‹

No extra prose in this bit โ€” the page goes straight into Function Documentation, and thatโ€™s where the real tea is. ๐Ÿ“


๐ŸŽ€ FUNCTION DOCUMENTATION ๐ŸŽ€

๐Ÿ’– clanhf ๐Ÿ’–

real function clanhf (character norm, character transr, character uplo,
       integer n, complex, dimension( 0: * ) a, real, dimension( 0: * ) work)

CLANHF returns the value of the 1-norm, or the Frobenius norm, or the infinity norm, or the element of largest absolute value of a Hermitian matrix in RFP format. ๐Ÿ’…

โœจ Purpose โœจ

CLANHF returns the value of the one norm, or the Frobenius norm, or the infinity norm, or the element of largest absolute value of a complex Hermitian matrix A in RFP format. ๐Ÿ‘‘

๐Ÿ’ซ Returns ๐Ÿ’ซ

This returns CLANHF, and the menu is giving:

CLANHF = ( max(abs(A(i,j))), NORM = 'M' or 'm'
         (
         ( norm1(A),         NORM = '1', 'O' or 'o'
         (
         ( normI(A),         NORM = 'I' or 'i'
         (
         ( normF(A),         NORM = 'F', 'f', 'E' or 'e'

where norm1 denotes the one norm of a matrix (maximum column sum), normI denotes the infinity norm of a matrix (maximum row sum) and normF denotes the Frobenius norm of a matrix (square root of sum of squares).

โš ๏ธ Note that max(abs(A(i,j))) is not a matrix norm. Periodt.

๐Ÿ’… Parameters ๐Ÿ’…

  • NORM โ€” is CHARACTER; specifies the value to be returned in CLANHF as described above. โœจ
  • TRANSR โ€” is CHARACTER; specifies whether the RFP format of A is normal or conjugate-transposed format.
    • = 'N': RFP format is Normal
    • = 'C': RFP format is Conjugate-transposed
  • UPLO โ€” is CHARACTER; on entry, UPLO specifies whether the RFP matrix A came from an upper or lower triangular matrix as follows:
    • UPLO = 'U' or 'u' RFP A came from an upper triangular matrix
    • UPLO = 'L' or 'l' RFP A came from a lower triangular matrix
  • N โ€” is INTEGER; the order of the matrix A. N >= 0. When N = 0, CLANHF is set to zero. ๐ŸŽ€
  • A โ€” is COMPLEX array, dimension ( N*(N+1)/2 ); on entry, the matrix A in RFP Format. RFP Format is described by TRANSR, UPLO and N as follows:
    • If TRANSR='N' then RFP A is (0:N,0:K-1) when N is even; K=N/2. RFP A is (0:N-1,0:K) when N is odd; K=N/2.
    • If TRANSR = 'C' then RFP is the Conjugate-transpose of RFP A as defined when TRANSR = 'N'. The contents of RFP A are defined by UPLO as follows:
    • If UPLO = 'U' the RFP A contains the ( N*(N+1)/2 ) elements of upper packed A either in normal or conjugate-transpose Format.
    • If UPLO = 'L' the RFP A contains the ( N*(N+1) /2 ) elements of lower packed A either in normal or conjugate-transpose Format. The LDA of RFP A is (N+1)/2 when TRANSR = 'C'. When TRANSR is 'N' the LDA is N+1 when N is even and is N when is odd. See the Note below for more details. Unchanged on exit. ๐Ÿ’œ
  • WORK โ€” is REAL array, dimension (LWORK), where LWORK >= N when NORM = 'I' or '1' or 'O'; otherwise, WORK is not referenced. ๐Ÿฆ‹

๐Ÿซถ Author ๐Ÿซถ

Big credit energy to:

  • Univ. of Tennessee
  • Univ. of California Berkeley
  • Univ. of Colorado Denver
  • NAG Ltd.

๐Ÿงš Further Details ๐Ÿงš

Okay, RFP layout time. First up: Standard Packed Format when N is even. Hereโ€™s an example where N = 6. ๐ŸŒˆ

      AP is Upper             AP is Lower

   00 01 02 03 04 05       00
      11 12 13 14 15       10 11
         22 23 24 25       20 21 22
            33 34 35       30 31 32 33
               44 45       40 41 42 43 44
                  55       50 51 52 53 54 55

Let TRANSR = 'N'. RFP holds AP as follows:

  • For UPLO = 'U' the upper trapezoid A(0:5,0:2) consists of the last three columns of AP upper. The lower triangle A(4:6,0:2) consists of conjugate-transpose of the first three columns of AP upper.
  • For UPLO = 'L' the lower trapezoid A(1:6,0:2) consists of the first three columns of AP lower. The upper triangle A(0:2,0:2) consists of conjugate-transpose of the last three columns of AP lower.

To denote conjugate we place -- above the element. This covers the case N even and TRANSR = 'N'. ๐Ÿ’€

         RFP A                   RFP A

                                -- -- --
        03 04 05                33 43 53
                                   -- --
        13 14 15                00 44 54
                                      --
        23 24 25                10 11 55

        33 34 35                20 21 22
        --
        00 44 45                30 31 32
        -- --
        01 11 55                40 41 42
        -- -- --
        02 12 22                50 51 52

Now let TRANSR = 'C'. RFP A in both UPLO cases is just the conjugate-transpose of RFP A above. One therefore gets:

          RFP A                   RFP A

     -- -- -- --                -- -- -- -- -- --
     03 13 23 33 00 01 02    33 00 10 20 30 40 50
     -- -- -- -- --                -- -- -- -- --
     04 14 24 34 44 11 12    43 44 11 21 31 41 51
     -- -- -- -- -- --                -- -- -- --
     05 15 25 35 45 55 22    53 54 55 22 32 42 52

We next consider Standard Packed Format when N is odd. We give an example where N = 5. ๐ŸŒธ

     AP is Upper                 AP is Lower

  00 01 02 03 04              00
     11 12 13 14              10 11
        22 23 24              20 21 22
           33 34              30 31 32 33
              44              40 41 42 43 44

Let TRANSR = 'N'. RFP holds AP as follows:

  • For UPLO = 'U' the upper trapezoid A(0:4,0:2) consists of the last three columns of AP upper. The lower triangle A(3:4,0:1) consists of conjugate-transpose of the first two columns of AP upper.
  • For UPLO = 'L' the lower trapezoid A(0:4,0:2) consists of the first three columns of AP lower. The upper triangle A(0:1,1:2) consists of conjugate-transpose of the last two columns of AP lower.

To denote conjugate we place -- above the element. This covers the case N odd and TRANSR = 'N'. ๐Ÿ‘‘

         RFP A                   RFP A

                                   -- --
        02 03 04                00 33 43
                                      --
        12 13 14                10 11 44

        22 23 24                20 21 22
        --
        00 33 34                30 31 32
        -- --
        01 11 44                40 41 42

Now let TRANSR = 'C'. RFP A in both UPLO cases is just the conjugate-transpose of RFP A above. One therefore gets:

           RFP A                   RFP A

     -- -- --                   -- -- -- -- -- --
     02 12 22 00 01             00 10 20 30 40 50
     -- -- -- --                   -- -- -- -- --
     03 13 23 33 11             33 11 21 31 41 51
     -- -- -- -- --                   -- -- -- --
     04 14 24 34 44             43 44 22 32 42 52

Definition at line 245 of file clanhf.f. ๐Ÿ’–


๐Ÿฆ‹ dlansf ๐Ÿฆ‹

double precision function dlansf (character norm, character transr,
       character uplo, integer n, double precision, dimension( 0: * ) a, double
       precision, dimension( 0: * ) work)

DLANSF returns the value of the 1-norm, or the Frobenius norm, or the infinity norm, or the element of largest absolute value of a symmetric matrix in RFP format. ๐Ÿซถ

โœจ Purpose โœจ

DLANSF returns the value of the one norm, or the Frobenius norm, or the infinity norm, or the element of largest absolute value of a real symmetric matrix A in RFP format. โœจ

๐Ÿ’ซ Returns ๐Ÿ’ซ

This returns DLANSF, and the menu is:

DLANSF = ( max(abs(A(i,j))), NORM = 'M' or 'm'
         (
         ( norm1(A),         NORM = '1', 'O' or 'o'
         (
         ( normI(A),         NORM = 'I' or 'i'
         (
         ( normF(A),         NORM = 'F', 'f', 'E' or 'e'

where norm1 denotes the one norm of a matrix (maximum column sum), normI denotes the infinity norm of a matrix (maximum row sum) and normF denotes the Frobenius norm of a matrix (square root of sum of squares).

โš ๏ธ Note that max(abs(A(i,j))) is not a matrix norm. No cap.

๐Ÿ’… Parameters ๐Ÿ’…

  • NORM โ€” is CHARACTER*1; specifies the value to be returned in DLANSF as described above. ๐ŸŒŸ
  • TRANSR

okay bestie, where were we โ€” right, the rest of DLANSF's parameter list. buckle up, we're finishing the boring-but-important bit first ๐Ÿ’…

  • TRANSR โ€” TRANSR is CHARACTER*1, and it tells you whether the RFP format of A is the normal one or the transposed one. = 'N': RFP format is Normal. = 'T': RFP format is Transpose. that's it, that's the whole flag ๐ŸŒธ
  • UPLO โ€” UPLO is CHARACTER*1. on entry it says whether the RFP matrix A came from an upper or a lower triangular matrix, like so: = 'U': RFP A came from an upper triangular matrix; = 'L': RFP A came from a lower triangular matrix. ๐Ÿฆ‹
  • N โ€” N is INTEGER, the order of the matrix A. N >= 0. and when N = 0, DLANSF is set to zero โ€” the empty matrix has no vibes to measure, so it just returns 0 ๐Ÿ˜Œ
  • A โ€” A is DOUBLE PRECISION array, dimension ( N*(N+1)/2 );. on entry it holds the upper (if UPLO = 'U') or lower (if UPLO = 'L') part of the symmetric matrix A, stored in RFP format. the original literally says "See the below for more details." โ€” yes, the "the" is doing nothing there, but I'm not gonna lie to you about what the manpage says ๐Ÿ™ˆ (the details are literally the next section, keep reading). Unchanged on exit. ๐Ÿ’–
  • WORK โ€” WORK is DOUBLE PRECISION array, dimension (MAX(1,LWORK)), where LWORK >= N when NORM = 'I' or '1' or 'O'; otherwise, WORK is not referenced. translation: sometimes it's scratch paper, sometimes it's just vibing in the corner uninvited ๐ŸŽ€

Author

  • Univ. of Tennessee
  • Univ. of California Berkeley
  • Univ. of Colorado Denver
  • NAG Ltd.

Further Details

okay so this is the part where the RFP layout finally gets explained, and ngl it's giving "math teacher with a whiteboard" but it is useful, so stay with me ๐Ÿงš

First we consider the Rectangular Full Packed (RFP) Format when N is even. example where N = 6 ๐Ÿ‘‡

    AP is Upper             AP is Lower

 00 01 02 03 04 05       00
    11 12 13 14 15       10 11
       22 23 24 25       20 21 22
          33 34 35       30 31 32 33
             44 45       40 41 42 43 44
                55       50 51 52 53 54 55

Let TRANSR = 'N'. RFP holds AP as follows:

  • For UPLO = 'U', the upper trapezoid A(0:5,0:2) consists of the last three columns of AP upper. The lower triangle A(4:6,0:2) consists of the transpose of the first three columns of AP upper.
  • For UPLO = 'L', the lower trapezoid A(1:6,0:2) consists of the first three columns of AP lower. The upper triangle A(0:2,0:2) consists of the transpose of the last three columns of AP lower.

This covers the case N even and TRANSR = 'N'. โœจ

      RFP A                   RFP A

     03 04 05                33 43 53
     13 14 15                00 44 54
     23 24 25                10 11 55
     33 34 35                20 21 22
     00 44 45                30 31 32
     01 11 55                40 41 42
     02 12 22                50 51 52

Now let TRANSR = 'T'. RFP A in both UPLO cases is just the transpose of RFP A above. one therefore gets, and I quote the layout exactly ๐Ÿ‘‡

        RFP A                   RFP A

   03 13 23 33 00 01 02    33 00 10 20 30 40 50
   04 14 24 34 44 11 12    43 44 11 21 31 41 51
   05 15 25 35 45 55 22    53 54 55 22 32 42 52

We then consider Rectangular Full Packed (RFP) Format when N is odd. example where N = 5 ๐Ÿฆ‹

   AP is Upper                 AP is Lower

 00 01 02 03 04              00
    11 12 13 14              10 11
       22 23 24              20 21 22
          33 34              30 31 32 33
             44              40 41 42 43 44

Let TRANSR = 'N'. RFP holds AP as follows:

  • For UPLO = 'U', the upper trapezoid A(0:4,0:2) consists of the last three columns of AP upper. The lower triangle A(3:4,0:1) consists of the transpose of the first two columns of AP upper.
  • For UPLO = 'L', the lower trapezoid A(0:4,0:2) consists of the first three columns of AP lower. The upper triangle A(0:1,1:2) consists of the transpose of the last two columns of AP lower.

This covers the case N odd and TRANSR = 'N'. ๐Ÿ‘‘

      RFP A                   RFP A

     02 03 04                00 33 43
     12 13 14                10 11 44
     22 23 24                20 21 22
     00 33 34                30 31 32
     01 11 44                40 41 42

Now let TRANSR = 'T'. RFP A in both UPLO cases is just the transpose of RFP A above. one therefore gets:

        RFP A                   RFP A

   02 12 22 00 01             00 10 20 30 40 50
   03 13 23 33 11             33 11 21 31 41 51
   04 14 24 34 44             43 44 22 32 42 52

fr fr that's the whole layout lore. screenshot it, tattoo it, whatever works ๐Ÿ’€

Definition at line 208 of file dlansf.f.


๐Ÿงฎ real function slansf (character norm, character transr, character uplo, integer n, real, dimension( 0: * ) a, real, dimension( 0: * ) work)

SLANSF โ€” the single-precision sibling of the thing we just read. same energy, REAL instead of DOUBLE PRECISION, still iconic ๐Ÿ’œ

Purpose

SLANSF returns the value of the one norm, or the Frobenius norm, or the infinity norm, or the element of largest absolute value of a real symmetric matrix A in RFP format. four different ways to judge a matrix's whole personality, pick your fighter ๐ŸŒˆ

Returns

here's the whole picker, laid out exactly:

   SLANSF = ( max(abs(A(i,j))), NORM = 'M' or 'm'
            (
            ( norm1(A),         NORM = '1', 'O' or 'o'
            (
            ( normI(A),         NORM = 'I' or 'i'
            (
            ( normF(A),         NORM = 'F', 'f', 'E' or 'e'

where norm1 denotes the one norm of a matrix (maximum column sum), normI denotes the infinity norm of a matrix (maximum row sum) and normF denotes the Frobenius norm of a matrix (square root of sum of squares).

๐Ÿšจ important caveat bestie: note that max(abs(A(i,j))) is not a matrix norm. the manpage says it plainly, and I'm not gonna let you walk around calling it one at a party ๐Ÿ˜ญ

Parameters

  • NORM โ€” NORM is CHARACTER*1 and specifies the value to be returned in SLANSF as described above. that's the knob that picks which norm you get ๐ŸŽ€
  • TRANSR โ€” TRANSR is CHARACTER*1. specifies whether the RFP format of A is normal or transposed format. = 'N': RFP format is Normal; = 'T': RFP format is Transpose. same deal as before, no cap โœจ
  • UPLO โ€” UPLO is CHARACTER*1. on entry, UPLO specifies whether the RFP matrix A came from an upper or lower triangular matrix as follows: = 'U': RFP A came from an upper triangular matrix; = 'L': RFP A came from a lower triangular matrix. ๐Ÿ’…
  • N โ€” N is INTEGER, the order of the matrix A. N >= 0. When N = 0, SLANSF is set to zero. zero-sized matrix, zero drama ๐Ÿซถ
  • A โ€” A is REAL array, dimension ( N*(N+1)/2 );. on entry, the upper (if UPLO = 'U') or lower (if UPLO = 'L') part of the symmetric matrix A stored in RFP format. and again the original says "See the below for more details." (still keeping that stray "the", it's part of the family now ๐Ÿ˜ญ). Unchanged on exit. ๐ŸŒธ
  • WORK โ€” WORK is REAL array, dimension (MAX(1,LWORK)), where LWORK >= N when NORM = 'I' or '1' or 'O'; otherwise, WORK is not referenced. same rule as its double-precision twin ๐Ÿฆ‹

Author

  • Univ. of Tennessee
  • Univ. of California Berkeley
  • Univ. of Colorado Denver
  • NAG Ltd.

Further Details

okay the RFP diagrams for this one are right below โ€” same layout lore as before but we're not done yet, keep scrolling bestie ๐Ÿ‘‡๐Ÿ’œ

Okay so RFP format time, bestie ๐Ÿ’… Weโ€™re talking Rectangular Full Packed (RFP) Format when N is even. Example: N = 6. Hereโ€™s the upper/lower packed vibe:

AP is Upper             AP is Lower

00 01 02 03 04 05       00
  11 12 13 14 15       10 11
     22 23 24 25       20 21 22
        33 34 35       30 31 32 33
           44 45       40 41 42 43 44
              55       50 51 52 53 54 55

Now let TRANSR = 'N'. RFP holds AP like this: for UPLO = 'U' the upper trapezoid A(0:5,0:2) is made of the last three columns of AP upper, and the lower triangle A(4:6,0:2) is the transpose of the first three columns of AP upper. For UPLO = 'L' the lower trapezoid A(1:6,0:2) is the first three columns of AP lower, and the upper triangle A(0:2,0:2) is the transpose of the last three columns of AP lower. That covers the case N even and TRANSR = 'N'. ๐Ÿ’–

        RFP A                   RFP A

       03 04 05                33 43 53
       13 14 15                00 44 54
       23 24 25                10 11 55
       33 34 35                20 21 22
       00 44 45                30 31 32
       01 11 55                40 41 42
       02 12 22                50 51 52

Now let TRANSR = 'T'. RFP A in both UPLO cases is just the transpose of RFP A above. So you get:

          RFP A                   RFP A

     03 13 23 33 00 01 02    33 00 10 20 30 40 50
     04 14 24 34 44 11 12    43 44 11 21 31 41 51
     05 15 25 35 45 55 22    53 54 55 22 32 42 52

Next up: Rectangular Full Packed (RFP) Format when N is odd. Example: N = 5. The packed AP upper/lower situation is giving:

AP is Upper                 AP is Lower

00 01 02 03 04              00
  11 12 13 14              10 11
     22 23 24              20 21 22
        33 34              30 31 32 33
           44              40 41 42 43 44

Let TRANSR = 'N'. RFP holds AP as follows: for UPLO = 'U' the upper trapezoid A(0:4,0:2) is the last three columns of AP upper, and the lower triangle A(3:4,0:1) is the transpose of the first two columns of AP upper. For UPLO = 'L' the lower trapezoid A(0:4,0:2) is the first three columns of AP lower, and the upper triangle A(0:1,1:2) is the transpose of the last two columns of AP lower. That covers the case N odd and TRANSR = 'N'. โœจ

        RFP A                   RFP A

       02 03 04                00 33 43
       12 13 14                10 11 44
       22 23 24                20 21 22
       00 33 34                30 31 32
       01 11 44                40 41 42

Now let TRANSR = 'T'. RFP A in both UPLO cases is just the transpose of RFP A above. One therefore gets:

          RFP A                   RFP A

     02 12 22 00 01             00 10 20 30 40 50
     03 13 23 33 11             33 11 21 31 41 51
     04 14 24 34 44             43 44 22 32 42 52
๐Ÿ“ Definition at line 208 of file slansf.f.

๐Ÿ’– double precision function zlanhf ๐Ÿ’–

   double precision function zlanhf (character norm, character transr,
       character uplo, integer n, complex*16, dimension( 0: * ) a, double
       precision, dimension( 0: * ) work)

ZLANHF returns the value of the 1-norm, or the Frobenius norm, or the infinity norm, or the element of largest absolute value of a Hermitian matrix in RFP format. Iconic, no cap ๐Ÿ’…

๐ŸŽฏ Purpose:

ZLANHF returns the value of the one norm, or the Frobenius norm, or the infinity norm, or the element of largest absolute value of a complex Hermitian matrix A in RFP format. ๐Ÿฆ‹

๐Ÿ“ฆ Returns

The return value is ZLANHF, and it picks its little outfit like this:

ZLANHF = ( max(abs(A(i,j))), NORM = 'M' or 'm'
         (
         ( norm1(A),         NORM = '1', 'O' or 'o'
         (
         ( normI(A),         NORM = 'I' or 'i'
         (
         ( normF(A),         NORM = 'F', 'f', 'E' or 'e'

where norm1 denotes the one norm of a matrix (maximum column sum), normI denotes the infinity norm of a matrix (maximum row sum) and normF denotes the Frobenius norm of a matrix (square root of sum of squares). Note that max(abs(A(i,j))) is not a matrix norm. ๐Ÿ’€

๐ŸŽ€ Parameters

  • NORM โ€” NORM is CHARACTER. Specifies the value to be returned in ZLANHF as described above. โœจ
  • TRANSR โ€” TRANSR is CHARACTER. Specifies whether the RFP format of A is normal or conjugate-transposed format.
    • = 'N': RFP format is Normal
    • = 'C': RFP format is Conjugate-transposed
  • UPLO โ€” UPLO is CHARACTER. On entry, UPLO specifies whether the RFP matrix A came from an upper or lower triangular matrix as follows:
    • UPLO = 'U' or 'u' RFP A came from an upper triangular matrix
    • UPLO = 'L' or 'l' RFP A came from a lower triangular matrix
  • N โ€” N is INTEGER. The order of the matrix A. N >= 0. When N = 0, ZLANHF is set to zero. ๐Ÿซถ
  • A โ€” A is COMPLEX*16 array, dimension ( N*(N+1)/2 ); On entry, the matrix A in RFP Format. RFP Format is described by TRANSR, UPLO and N as follows:
    • If TRANSR='N' then RFP A is (0:N,0:K-1) when N is even; K=N/2. RFP A is (0:N-1,0:K) when N is odd; K=N/2.
    • If TRANSR = 'C' then RFP is the Conjugate-transpose of RFP A as defined when TRANSR = 'N'.
    • The contents of RFP A are defined by UPLO as follows: If UPLO = 'U' the RFP A contains the ( N*(N+1)/2 ) elements of upper packed A either in normal or conjugate-transpose Format. If UPLO = 'L' the RFP A contains the ( N*(N+1) /2 ) elements of lower packed A either in normal or conjugate-transpose Format.
    • The LDA of RFP A is (N+1)/2 when TRANSR = 'C'. When TRANSR is 'N' the LDA is N+1 when N is even and is N when is odd. See the Note below for more details.
    • Unchanged on exit.
  • WORK โ€” WORK is DOUBLE PRECISION array, dimension (LWORK), where LWORK >= N when NORM = 'I' or '1' or 'O'; otherwise, WORK is not referenced.

๐Ÿ‘‘ Author

  • Univ. of Tennessee
  • Univ. of California Berkeley
  • Univ. of Colorado Denver
  • NAG Ltd.

๐ŸŒธ Further Details: ๐ŸŒธ

ok so first up, bestie: we start with Standard Packed Format when N is even ๐Ÿ’– and the example we're gonna walk through is N = 6.

      AP is Upper             AP is Lower

   00 01 02 03 04 05       00
      11 12 13 14 15       10 11
         22 23 24 25       20 21 22
            33 34 35       30 31 32 33
               44 45       40 41 42 43 44
                  55       50 51 52 53 54 55

Now let TRANSR = 'N'. RFP holds AP like this:

  • For UPLO = 'U', the upper trapezoid A(0:5,0:2) consists of the last three columns of AP upper. The lower triangle A(4:6,0:2) consists of conjugate-transpose of the first three columns of AP upper.
  • For UPLO = 'L', the lower trapezoid A(1:6,0:2) consists of the first three columns of AP lower. The upper triangle A(0:2,0:2) consists of conjugate-transpose of the last three columns of AP lower.

To denote conjugate we place -- above the element. This covers the case N even and TRANSR = 'N'. (yes, the little dashes floating above are doing all the heavy lifting โ€” that's the whole conjugate bit, no cap โœจ)

        RFP A                   RFP A

                                -- -- --
        03 04 05                33 43 53
                                   -- --
        13 14 15                00 44 54
                                      --
        23 24 25                10 11 55

        33 34 35                20 21 22
        --
        00 44 45                30 31 32
        -- --
        01 11 55                40 41 42
        -- -- --
        02 12 22                50 51 52

Now let TRANSR = 'C'. RFP A in both UPLO cases is just the conjugate-transpose of RFP A above. One therefore gets:

          RFP A                   RFP A

     -- -- -- --                -- -- -- -- -- --
     03 13 23 33 00 01 02    33 00 10 20 30 40 50
     -- -- -- -- --                -- -- -- -- --
     04 14 24 34 44 11 12    43 44 11 21 31 41 51
     -- -- -- -- -- --                -- -- -- -- --
     05 15 25 35 45 55 22    53 54 55 22 32 42 52

We next consider Standard Packed Format when N is odd ๐Ÿฆ‹ and this time the example is N = 5.

    AP is Upper                 AP is Lower

   00 01 02 03 04              00
      11 12 13 14              10 11
         22 23 24              20 21 22
            33 34              30 31 32 33
               44              40 41 42 43 44

Let TRANSR = 'N'. RFP holds AP as follows:

  • For UPLO = 'U', the upper trapezoid A(0:4,0:2) consists of the last three columns of AP upper. The lower triangle A(3:4,0:1) consists of conjugate-transpose of the first two columns of AP upper.
  • For UPLO = 'L', the lower trapezoid A(0:4,0:2) consists of the first three columns of AP lower. The upper triangle A(0:1,1:2) consists of conjugate-transpose of the last two columns of AP lower.

To denote conjugate we place -- above the element. This covers the case N odd and TRANSR = 'N'. (same little dash situation, different parity โ€” the trapezoids just shift around, iykyk ๐ŸŒธ)

        RFP A                   RFP A

                                  -- --
        02 03 04                00 33 43
                                     --
        12 13 14                10 11 44

        22 23 24                20 21 22
        --
        00 33 34                30 31 32
        -- --
        01 11 44                40 41 42

Now let TRANSR = 'C'. RFP A in both UPLO cases is just the conjugate-transpose of RFP A above. One therefore gets:

          RFP A                   RFP A

     -- -- --                   -- -- -- -- -- --
     02 12 22 00 01             00 10 20 30 40 50
     -- -- -- --                   -- -- -- -- --
     03 13 23 33 11             33 11 21 31 41 51
     -- -- -- -- --                   -- -- -- --
     04 14 24 34 44             43 44 22 32 42 52

And where does this whole diagram party live in the source? Right here, bestie:

Definition at line 245 of file zlanhf.f.


๐Ÿ‘‘ AUTHOR ๐Ÿ‘‘

Generated automatically by Doxygen for LAPACK from the source code. (the robots wrote the paperwork, we just made it cute ๐Ÿค–๐Ÿ’…)


that's a wrap on lanhf(3), bestie โ€” go forth and pack those standard packed formats ๐Ÿซถ this whole page came to you straight from LAPACK, Version 3.12.0, and you absolutely ate it. periodt. ๐Ÿ’–โœจ
๐Ÿ“ฆ where this page comes from