NAG Library Routine Document

f06wqf  (zhfrk)

 Contents

    1  Purpose
    7  Accuracy

1
Purpose

f06wqf (zhfrk) performs one of the Hermitian rank-k update operations
CαAAH + βC   or   CαAHA + βC ,  
where A is a complex matrix, C is an n by n complex Hermitian matrix stored in Rectangular Full Packed (RFP) format, and α and β are real scalars.

2
Specification

Fortran Interface
Subroutine f06wqf ( transr, uplo, trans, n, k, alpha, a, lda, beta, c)
Integer, Intent (In):: n, k, lda
Real (Kind=nag_wp), Intent (In):: alpha, beta
Complex (Kind=nag_wp), Intent (In):: a(lda,*)
Complex (Kind=nag_wp), Intent (Inout):: c(n*(n+1)/2)
Character (1), Intent (In):: transr, uplo, trans
C Header Interface
#include nagmk26.h
void  f06wqf_ ( const char *transr, const char *uplo, const char *trans, const Integer *n, const Integer *k, const double *alpha, const Complex a[], const Integer *lda, const double *beta, Complex c[], const Charlen length_transr, const Charlen length_uplo, const Charlen length_trans)
The routine may be called by its LAPACK name zhfrk.

3
Description

f06wqf (zhfrk) performs one of the Hermitian rank-k update operations
CαAAH + βC   or   CαAHA + βC ,  
where A is a complex matrix, C is an n by n complex Hermitian matrix stored in Rectangular Full Packed (RFP) format, and α and β are real scalars. The RFP storage format is described in Section 3.3.3 in the F07 Chapter Introduction.
If n=0 or if β=1.0 and either k=0 or α=0.0 then f06wqf (zhfrk) returns immediately. If β=0.0 and either k=0 or α=0.0 then C is set to the zero matrix.

4
References

Gustavson F G, Waśniewski J, Dongarra J J and Langou J (2010) Rectangular full packed format for Cholesky's algorithm: factorization, solution, and inversion ACM Trans. Math. Software 37, 2

5
Arguments

1:     transr – Character(1)Input
On entry: specifies whether the normal RFP representation of C or its conjugate transpose is stored.
transr='N'
The matrix C is stored in normal RFP format.
transr='C'
The conjugate transpose of the RFP representation of the matrix C is stored.
Constraint: transr='N' or 'C'.
2:     uplo – Character(1)Input
On entry: specifies whether the upper or lower triangular part of C is stored in RFP format.
uplo='U'
The upper triangular part of C is stored in RFP format.
uplo='L'
The lower triangular part of C is stored in RFP format.
Constraint: uplo='U' or 'L'.
3:     trans – Character(1)Input
On entry: specifies the operation to be performed.
trans='N'
CαAAH+βC.
trans='C'
CαAHA+βC.
Constraint: trans='N' or 'C'.
4:     n – IntegerInput
On entry: n, the order of the matrix C.
Constraint: n0.
5:     k – IntegerInput
On entry: k, the number of columns of A if trans='N', or the number of rows of A if trans='C'.
Constraint: k0.
6:     alpha – Real (Kind=nag_wp)Input
On entry: the scalar α.
7:     alda* – Complex (Kind=nag_wp) arrayInput
Note: the second dimension of the array a must be at least max1,k if trans='N' and at least max1,n if trans='C'.
On entry: the matrix A; A is n by k if trans='N', or k by n if trans='C'. If alpha=0.0, a is not referenced.
8:     lda – IntegerInput
On entry: the first dimension of the array a as declared in the (sub)program from which f06wqf (zhfrk) is called.
Constraints:
  • if trans='N', lda max1,n ;
  • if trans='C', lda max1,k .
9:     beta – Real (Kind=nag_wp)Input
On entry: the scalar β.
10:   cn×n+1/2 – Complex (Kind=nag_wp) arrayInput/Output
On entry: the upper or lower triangular part (as specified by uplo) of the n by n Hermitian matrix C, stored in RFP format (as specified by transr). The storage format is described in detail in Section 3.3.3 in the F07 Chapter Introduction.
On exit: the updated matrix C, that is its upper or lower triangular part stored in RFP format.

6
Error Indicators and Warnings

None.

7
Accuracy

Not applicable.

8
Parallelism and Performance

f06wqf (zhfrk) makes calls to BLAS and/or LAPACK routines, which may be threaded within the vendor library used by this implementation. Consult the documentation for the vendor library for further information.
Please consult the X06 Chapter Introduction for information on how to control and interrogate the OpenMP environment used within this routine. Please also consult the Users' Note for your implementation for any additional implementation-specific information.

9
Further Comments

None.

10
Example

This example reads in the lower triangular part of a symmetric matrix C which it converts to RFP format. It also reads in α, β and a 4 by 3 matrix A and then performs the Hermitian rank-3 update CαAAH+βC.

10.1
Program Text

Program Text (f06wqfe.f90)

10.2
Program Data

Program Data (f06wqfe.d)

10.3
Program Results

Program Results (f06wqfe.r)

© The Numerical Algorithms Group Ltd, Oxford, UK. 2017