45
1 Quadruple Precision Eigenvalue Calculation Library QPEigen_K Ver.1.0 User s Manual July, 2013 Japan Atomic Energy Agency

Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

  • Upload
    vutuyen

  • View
    236

  • Download
    5

Embed Size (px)

Citation preview

Page 1: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

1

Quadruple Precision

Eigenvalue

Calculation Library

QPEigen_K Ver.1.0

User’s Manual

July, 2013

Japan Atomic Energy Agency

Page 2: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

1

Contents

1 Overview ..........................................................................................................................1

2 Matrix diagonalization ...................................................................................................2

3 Quadruple precision algorithm ......................................................................................2

4 Reference .........................................................................................................................3

5 Directory structure .........................................................................................................3

6 Required software ...........................................................................................................4

7 Installation ......................................................................................................................4

8 Verification and performance evaluation programs .....................................................6

9 Sample programs ............................................................................................................7

10 Subroutines details ................................................................................................... 11

Page 3: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

1

1 Overview

The R&D Office of Simulation Technology at the Center for Computational Science &

e-Systems in the Japan Atomic Energy Agency has been working on research and

development (R&D) for computational techniques relevant to one of the R&D targets in

the mid-term plan for the second mid-term, "developing high-precision simulation

technologies that can be used for clarification of degradation phenomena of the

structural materials of a nuclear reactor, prediction of the material properties of

fuel-related actinide compounds, clarification of the relationship between the structure

and function of the highly-efficient thermoelectric materials, electric power supply

materials, and superconducting materials." In the aforementioned plan, it is a common

challenge of computational science to develop numerical calculation techniques for use

in the study of material properties, and it is indispensable to develop methods to

accurately calculate an electronic state based on quantum mechanics (quantum

many-body problem). In order to accurately solve a quantum many-body problem, a very

large degree of freedom must be handled without approximation, and therefore, it is

required to conduct a large-scale numerical calculation while maintaining sufficient

precision. At present, a large-scale computation, such as solving a quantum many-body

problem, is made possible by using a parallel computer. As long as the total amount of

the available memory space collected from each processor is sufficiently large, a

problem as large as the computational resources allow is approachable. In contrast, a

significant amount of computational error accumulates during an actual large-scale

calculation for obtaining accurate quantum states because an enormous number of

operations are required to do so. (A computer calculates with a certain number of

significant digits. At every calculation, a rounding error is added. The rounding errors

accumulate as the number of calculations increases.)

Until recently, the scale of a simulation was not sufficiently large to be problematic in

terms of its error, but it has been pointed out that, when a simulation that requires a

very large scale computer such as the K computer to run at its maximum performance is

conducted, the rounding errors may add up significantly, and the simulation result may

lose most of its significant digits. (It was actually observed that the result of an

eigenvalue problem that took all 4096 CPU nodes of a previous version of Earth

Simulator to calculate had only a couple of significant digits.)

Under the situation being as described above, extending an eigenvalue calculation

routine, one of the routines that perform basic operations and are used frequently for a

Page 4: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

1

computer simulation, to quadruple precision is an R&D activity indispensable for

facilitating a high-precision very-large-scale parallel simulation in the future. The

priority of this R&D activity can be judged as very high because this problem is

universal and applicable to all large-scale simulations. Extending a routine to

quadruple precision has already been proved effective in our project to convert Basic

Linear Algebra Subprograms (BLAS) to quadruple precision, which was conducted prior

to this project.

We have developed EigenK, a double precision version of an eigenvalue calculation

library used for calculating the eigenvalues and eigenvectors of a real symmetric matrix

and a Hermitian matrix. When you calculate the eigenvalues and eigenvectors of a

symmetric matrix with the EigenK library, you can select whether to use the tridiagonal

matrix algorithm or the pentadiagonal matrix algorithm. The quadruple precision

eigenvalue calculation library (hereinafter referred to as "QPEigen_K library") we have

developed this time is a quadruple precision version of the EigenK library routines that

use the tridiagonal matrix algorithm to calculate the eigenvalues and eigenvectors of a

real symmetric matrix.

This document describes how to use the QPEigen_K library.

2 Matrix diagonalization

Matrix diagonalization is essentially equivalent to eigenvalue calculation and

frequently used in structural analysis and quantum mechanics calculations. Eigenvalue

calculation is a process of calculating an eigenvalue and eigenvector that satisfy

when a matrix is given. QPEigen_K is a library used for calculating the

eigenvalues of a real symmetric matrix via tridiagonalization.

3 Quadruple precision algorithm

IEEE 754- compliant quadruple precision (128 bit) floating point operations have

already been implemented in some languages including the latest Fortran. But

hardware has not been optimized for those operations yet, and they are often executed

as arbitrary precision calculations. As a result, their calculation speed is extremely slow

compared to double precision operations.

In order to improve both precision and speed of the calculation, QPEigen_K uses the

double-double algorithm proposed by D.H.Bailey. In this algorithm, one high-precision

Page 5: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

1

number is represented by a combination of two double precision numbers, and a

quadruple precision operation is implemented by combining double precision operations.

The range and precision of the numeric representation used in the double-double

algorithm is slightly worse than those of the genuine quadruple precision but still

almost doubled compared to the standard double precision. This algorithm allows

calculations on such high-precision numbers using just a combination of double

precision operations and therefore is highly effective for implementing a large-scale

high-precision simulation.

4 Reference

BaileyHD. High-Precision Software Directory.

http://crd-legacy.lbl.gov/~dhbailey/mpdist.

Susumu Yamada, Narimasa Sasa, Toshiyuki Imamura, and Masahiko Machida:

“Introduction to quadruple precision basic linear algebra routines QPBLAS and its

application,” IPSJ SIG Technical Report, Vol. 2012-HPC-137, No. 23, pp. 1-6, 2012.

5 Directory structure

The directory structure in the medium is described below.

Directory name Description

ddmpi Stores a set of quadruple precision (DD) MPI communication

library files including source files.

ddlapack Stores a set of DDLAPACK files including source files.

ddscalapack Stores a set of DDScaLAPACK files including source files.

ddeigen_s Stores a set of DDEigen_s files including source files.

ddeigen_s_test Stores a set of programs that run quadruple precision (DD) tests.

eigen_s Stores a set of double precision Eigen_s files including source files.

eigen_s_test Stores a set of programs that run double precision Eigen_s tests.

Page 6: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

1

6 Required software

The QPEigen library uses DDBLAS, BLAS, quadruple precision ScaLAPACK

(hereinafter "DDScaLAPACK"), original ScaLAPACK, quadruple precision LAPACK

(hereinafter "DDLAPACK"), original LAPACK, and quadruple precision MPI

communication library.

Therefore, you must specify appropriate options to link DDBLAS, DDScaLAPACK, and

DDLAPACK when you link (when load modules are created). Those options are

specified in the configure command.

7 Installation

Enter the following commands to a terminal to create a Makefile that matches a user

environment and then compile.

tar xzf QPEigen_K-version.tar.gz

cd QPEigen_K-version

./configure options

make

The major options you may consider using in the configure command and their

meanings are as follows.

FC=f90_compiler Specifies the Fortran compiler.

CC=c_compiler Specifies the C compiler.

FCFLAGS=options Specifies Fortran compile options.

Specifies parallel computation and

optimization settings.

CFLAGS=options Specifies C compile options.

LDFLAGS=options Specifies link options.

--prefix=path Changes the install directory.

--disable-openmp Disables parallel processing via OpenMP.

If this option is not specified, parallel

processing is enabled using OpenMP.

Page 7: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

1

Examples of minimum options of the configure command necessary for compile are as

follows.

Example: When GNU C and GNU Fortran are used

./configure CC=mpicc FC=mpif90 --disable-openmp ¥

LDFLAGS="-L../lib/ -L../../lib –L../lib" ¥

FCFLAGS="-fdollar-ok" LIBS="-lddblas -lscalapack -llapack -lblas"

Example: When Intel C and Intel Fortran are used

./configure CC=mpiicc FC=mpiifort CFLAGS="-fp-model strict"

FCFLAGS="-fp-model strict" --disable-openmp ¥

LDFLAGS="-L../../lib –L../lib" ¥

LIBS="-lddblas -lscalapack -llapack -lblas"

The following list shows options for the make command.

make Simple "make" is the same as "make all".

make all Compiles all source codes.

make lib Compiles only the libraries.

make test

Compiles only the test programs.

Note that if the lib folder does not contain dependent

libraries (ddblas, blas, lapack, and scalapack), an error is

output and then stops.

If other dependent libraries (ddmpi, ddlapack,

ddscalapack, and ddeigen_s), which are included in the

package, cannot be found, "make lib" is automatically

executed.

make sample Compiles sample programs.

make ddmpi Compiles only ddmpi.

make ddlapack Compiles only ddlapack.

make ddscalapack Compiles only ddscalapack.

make ddeigen_s Compiles only ddeigen_s.

make clean Deletes all compiled files.

make clean-test Deletes all files related to test programs.

make clean-[library] Deletes all files related to the specific library.

Page 8: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

1

If the make is successful, the following libraries and programs are created.

ddlapack/libddlapack.a DDLAPACK library

ddmpi/libMpifdd1.a DDMPI library

ddmpi/libMpifdd2.a DDMPI library

ddscalapack/libddscalapack.a DDScaLAPACK library

eigen_s/libEigen_s.a Double precision Eigen library

ddeigen_s/libddEigen_s.a Double-double quadruple precision Eigen library

eigen_s_test/test_frank_d Double precision Frank matrix eigenvalue

verification program

eigen_s_test/test_random_d Double precision random matrix eigenvalue

verification program

ddeigen_s_test/test_frank_d Double-double quadruple precision Frank matrix

eigenvalue verification program

ddeigen_s_test/test_random_d Double-double quadruple precision random

matrix eigenvalue verification program

sample/frank5_sample_dd Sample program for calculating the eigenvalues

of the Frank matrix of order 5.

sample/hilbert5_sample_dd Sample program for calculating the eigenvalues

of the Hilbert matrix of order 5.

8 Verification and performance evaluation

programs

After you follow the procedure in 7 and finish the compile process, enter the following

commands.

cd ddeigen_s_test

./test_frank_dd (executing the Frank matrix test)

./test_random_dd (executing the random matrix test)

When you execute a test program, the accuracy of the calculation is output to the

standard output. You can determine whether calculation is performed in quadruple

Page 9: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

1

precision based on the accuracy of the calculation. The accuracy of the calculation is

calculated as follows.

(Accuracy of calculation) = nnn xwAx max

nw : Eigenvalues calculated by numerical solution

A : Matrix set up for precision verification

nx : Eigenvectors calculated by numerical solution

Figure 8-1 shows an example of standard output. The output of the accuracy of the

calculation is shown in the red box.

Figure 8-1 Example of Standard Output after Executing a Test Program

For information about a procedure for calling each routine and a description of the

arguments, see 0.

9 Sample programs

The sample directory contains some QPEigen_K sample programs written in Fortran77.

frank5_sample_dd Diagonalizing the Frank matrix of order 5 in double-double

quadruple precision

hilbert5_sample_dd Diagonalizing the Hilbert matrix of order 5 in double-double

quadruple precision

9.1 Diagonalizing the Frank matrix (frank5_sample_dd)

Frank matrices are ill-conditioned matrices with known eigenvalues and used in a

benchmark test for the numerical calculation of eigenvalues. Frank matrix of order 5 is

as follows.

Page 10: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

1

A quadruple precision matrix is given by substituting the elements of the

Frank matrix for the high word and 0.0d for the low word. The cstab_get_optdim

subroutine is called beforehand to obtain the size of the necessary work area. The

ddmatrix_adjust_s subroutine is called to copy the matrix to the work area, and then

the ddeigen_s subroutine is called to calculate the eigenvalues and eigenvectors.

9.2 Diagonalizing the Hilbert matrix (hilbert5_sample_dd)

Hilbert matrices are typical badly conditioned matrices often used in a benchmark test

for numerical calculation. Hilbert matrix of order 5 is as follows.

A quadruple precision matrix is given by substituting the elements of the

Hilbert matrix as the results of quadruple precision divisions for the high word and low

word. The cstab_get_optdim subroutine is called beforehand to obtain the size of

necessary work area. The ddmatrix_adjust_s subroutine is called to copy the matrix to

the work area, and then the ddeigen_s subroutine is called to calculate the eigenvalues

and eigenvectors.

9.3 Execution of sample programs

Those sample programs have already been compiled during the make, and you can, for

example, execute frank5_sample_dd by entering as follows.

cd sample

./frank5_sample_dd

If you want to compile this program by yourself, perform, for example, the following.

Page 11: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

1

mpiifort frank5_sample_dd.f -I../ddeigen_s ¥

../ddeigen_s/libddEigen_s.a ../ddscalapack/libddscalapack.a ¥

../ddlapack/libddlapack.a ¥

../ddmpi/libMpifdd1.a ../ddmpi/libMpifdd2.a ¥

../../lib/libddblas.a ../../lib/libscalapack.a ¥

../../lib/liblapack.a ../../lib/libblas.a

The source code of the sample program "frank5_sample_dd.f" is as follows.

program frank5_sample_dd

use ddcommunication_s, only : eigen_init

& , eigen_free

implicit double precision (a-h,o-v,x-z)

double precision, allocatable :: ah(:,:), al(:,:)

double precision, pointer :: bh(:), bl(:)

double precision, pointer :: zh(:), zl(:)

double precision, pointer :: wh(:), wl(:)

logical iexist

!

include 'mpif.h'

include 'trd.h'

!

call mpi_init(ierr)

call mpi_comm_rank(mpi_comm_world,i$inod,ierr)

call mpi_comm_size(mpi_comm_world,i$nnod,ierr)

n=5

allocate(ah(n,n),al(n,n))

call eigen_init(2)

NPROW = size_of_col

NPCOL = size_of_row

nx = ((n-1)/NPROW+1)

call CSTAB_get_optdim(nx, 2, 1, 2, nm)

Page 12: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

1

! call CSTAB_get_optdim(nx, 6, 16*4, 16*4*2, nm)

call eigen_free(0)

NB = 32

! NB = 64+32

nmz = ((n-1)/NPROW+1)

nmz = ((nmz-1)/NB+1)*NB+1

nmw = ((n-1)/NPCOL+1)

nmw = ((nmw-1)/NB+1)*NB+1

larray = MAX(nmz,nm)*nmw

allocate( bh(larray), bl(larray),zh(larray),zl(larray),

& wh(n),wl(n), stat=istat)

if(istat.ne.0) then

print*,"Memory exhausted"

call flush(6)

stop

endif

ah(1,1:5) = (/ 5.0d0, 4.0d0, 3.0d0, 2.0d0, 1.0d0 /)

ah(2,1:5) = (/ 4.0d0, 4.0d0, 3.0d0, 2.0d0, 1.0d0 /)

ah(3,1:5) = (/ 3.0d0, 3.0d0, 3.0d0, 2.0d0, 1.0d0 /)

ah(4,1:5) = (/ 2.0d0, 2.0d0, 2.0d0, 2.0d0, 1.0d0 /)

ah(5,1:5) = (/ 1.0d0, 1.0d0, 1.0d0, 1.0d0, 1.0d0 /)

al(1,1:5) = (/ 0.0d0, 0.0d0, 0.0d0, 0.0d0, 0.0d0 /)

al(2,1:5) = (/ 0.0d0, 0.0d0, 0.0d0, 0.0d0, 0.0d0 /)

al(3,1:5) = (/ 0.0d0, 0.0d0, 0.0d0, 0.0d0, 0.0d0 /)

al(4,1:5) = (/ 0.0d0, 0.0d0, 0.0d0, 0.0d0, 0.0d0 /)

al(5,1:5) = (/ 0.0d0, 0.0d0, 0.0d0, 0.0d0, 0.0d0 /)

call ddmatrix_adjust_s(n, ah, al, bh, bl, nm)

call ddeigen_s(n, bh, bl, nm, wh, wl, zh, zl, nm, m, 1)

write(*,*) 'EigenValue=', wh

Page 13: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

1

deallocate(ah,al)

deallocate(bh,bl)

deallocate(zh,zl)

deallocate(wh,wl)

*

call MPI_Finalize(ierr)

end

10 Subroutines details

Table 4-1 shows a list of routine modules in the QPEigen library.

Routine name Function

ddeigen_s

Calculating the eigenvalues and eigenvectors of a real symmetric

matrix by tridiagonalizing the matrix using the Householder

method. Executes a series of actions: tridiagonalization,

eigenvalue calculation, and eigenvector calculation.

ddeigen_trd Tridiagonalizes a real symmetric matrix using HouseHolder

tridiagonalization.

ddeigen_dc

Calculates the eigenvalues of an input matrix using the

divide-and-conquer algorithm if the input matrix is a tridiagonal

matrix obtained by HouseHolder tridiagonalization of a real

symmetric matrix.

ddeigen_tbk Calculates the eigenvectors of the tridiagonal matrix obtained by

HouseHolder tridiagonalization of a real symmetric matrix.

ddmatrix_adjust

The DDEigen library uses two-dimensional cyclic distribution.

This conversion routine is used for setting up the data

distribution of a matrix to support cyclic distribution. This

routine must be called before using this library.

ddcommunication_s Module used for MPI communication

Page 14: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

1

Routine name ddeigen_s

Function

Calculating the eigenvalues and eigenvectors of a real symmetric matrix by tridiagonalizing the matrix using the Householder method. Executes a series of actions: tridiagonalization, eigenvalue calculation, and eigenvector calculation.

Specification ddeigen_s(n, ah, al, lda, wh, wl, zh, zl, ldz, m, ifl) Arguments Descriptions i/o Original arguments n Dimension of a matrix integer i

ah High word of quadruple precision real matrix

double i a (real(8))

al Low word of quadruple precision real matrix

double i a (real(8))

lda Size of array A integer i wh High word of eigen values double o w(real(8)) wl Low word of eigen values double o w(real(8)) zh High word of eigen vectors double o z(real(8)) zl Low word of eigen vectors double o z(real(8)) ldz Size of array Z integer i m Blocking factor integer i about 32 to 128 ifl Option for output eigen vectors integer i 0 or 1

Routine name ddeigen_trd

Function Tridiagonalizes a real symmetric matrix using HouseHolder tridiagonalization

Specification ddeigen_trd(n, ah, al, lda, dh, dl, eh, el, m0)

Arguments Descriptions i/o Original arguments

n Dimension of a matrix integer i

ah High word of quadruple precision real matrix

double i a (real(8))

al Low word of quadruple precision real matrix

double i a (real(8))

lda Size of array A integer i dh High word of diagonal components double o d(real(8)) dl Low word of diagonal components double o d(real(8)) eh High word of subdiagonal components double o e(real(8)) el Low word of subdiagonal components double o e(real(8)) m Blocking factor integer i

Routine name ddeigen_trd_main1 Specification ddeigen_trd_main1(n, ah, al, d_outh, d_outl, e_outh, e_outl, m0) Arguments Type i/o Original arguments n integer i wh double o w(real(8)) wl double o w(real(8)) eh double i e(real(8)) el double i e(real(8)) zh double o z(real(8)) zl double o z(real(8)) ldz integer i info integer o

Page 15: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

2

Routine name ddeigen_trd_main2

Specification ddeigen_trd_main2(ah, al, nm, d_outh, d_outl, e_outh, e_outl, n, nv, m_orig, wh, wl, u_xh, u_xl, u_yh, u_yl, v_xh, v_xl, v_yh, v_yl, u_th, u_tl, v_th, v_tl, d_th, d_tl)

Arguments Type i/o Original arguments ah double i/o a(real(8)) al double i/o a(real(8)) nm integer i d_outh double o d_out(real(8)) d_outl double o d_out(real(8)) e_outh double o e_out(real(8)) e_outl double o e_out(real(8)) n integer i nv integer i m_orig integer i u_xh double i/o u_x(real(8)) u_xl double i/o u_x(real(8)) u_yh double i/o u_y(real(8)) u_yl double i/o u_y(real(8)) v_xh double i/o v_x(real(8)) v_xl double i/o v_x(real(8)) v_yh double i/o v_y(real(8)) v_yl double i/o v_y(real(8)) u_th double i u_t(real(8)) u_tl double i u_t(real(8)) v_th double i v_t(real(8)) v_tl double i v_t(real(8)) d_th double i d_t(real(8)) d_tl double i d_t(real(8))

Routine name ddeigen_trd_init

Specification ddeigen_trd_init(ah, al, nm, n, d_outh, d_outl, e_outh, e_outl, u_th, u_tl, v_th, v_tl, nv)

Arguments Type i/o Original arguments ah double i/o a(real(8)) al double i/o a(real(8)) nm integer i n integer i d_outh double o d_out(real(8)) d_outl double o d_out(real(8)) e_outh double o e_out(real(8)) e_outl double o e_out(real(8)) u_th double i u_t(real(8)) u_tl double i u_t(real(8)) v_th double i v_t(real(8)) v_tl double i v_t(real(8)) nv integer i

Routine name ddeigen_trd_finalize

Page 16: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

3

Specification ddeigen_trd_finalize(ah, al, nm, n, d_outh, d_outl, e_outh, e_outl, u_th, u_tl)

Arguments Type i/o Original arguments ah double i/o a(real(8)) al double i/o a(real(8)) nm integer i n integer i d_outh double o d_out(real(8)) d_outl double o d_out(real(8)) e_outh double o e_out(real(8)) e_outl double o e_out(real(8)) u_th double i u_t(real(8)) u_tl double i u_t(real(8))

Routine name ddeigen_trd_Au

Specification ddeigen_trd_Au(ah, al, nm, u_xh, u_xl, u_yh, u_yl, v_xh, v_xl, nv, u_th, u_tl, v_th, v_tl, d_th, d_tl, I, i_base, m)

Arguments Type i/o Original arguments ah double i/o a(real(8)) al double i/o a(real(8)) nm integer i u_xh double i/o u_x(real(8)) u_xl double i/o u_x(real(8)) u_yh double i/o u_y(real(8)) u_yl double i/o u_y(real(8)) v_xh double i/o v_x(real(8)) v_xl double i/o v_x(real(8)) nv integer i u_th double i u_t(real(8)) u_tl double i u_t(real(8)) v_th double i v_t(real(8)) v_tl double i v_t(real(8)) d_th double i d_t(real(8)) d_tl double i d_t(real(8)) i integer i i_base integer i m integer i

Routine name ddeigen_trd_Au_step1

Specification ddeigen_trd_Au_step1(ah, al, nm, u_xh, u_xl, u_yh, u_yl, u_th, u_tl, v_th, v_tl, n1, n2, col_local, row_local, nv, blk_0, thread_rank, thread_size)

Arguments Type i/o Original arguments ah double i/o a(real(8)) al double i/o a(real(8)) nm integer i u_xh double i/o u_x(real(8)) u_xl double i/o u_x(real(8)) u_yh double i/o u_y(real(8)) u_yl double i/o u_y(real(8)) u_th double i/o u_t(real(8))

Page 17: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

4

u_tl double i/o u_t(real(8)) v_th double i/o v_t(real(8)) v_tl double i/o v_t(real(8)) n1 integer i n2 integer i col_local integer i row_local integer i nv integer i blk_0 integer i thread_rank integer i thread_size integer i

Routine name ddeigen_trd_Au_step2

Specification ddeigen_trd_Au_step2(u_th, u_tl, u_zh, u_zl, v_th, v_tl, v_zh, v_zl, nv, col_local, row_local, thread_rank, thread_size)

Arguments Type i/o Original arguments u_th double o u_t(real(8)) u_tl double o u_t(real(8)) u_zh double i u_z(real(8)) u_zl double i u_z(real(8)) v_th double o v_t(real(8)) v_tl double o v_t(real(8)) v_zh double i v_z(real(8)) v_zl double i v_z(real(8)) nv integer i col_local integer i row_local integer i thread_rank integer i thread_size integer i

Routine name ddeigen_trd_Au_step3

Specification ddeigen_trd_Au_step3(u_xh, u_xl, u_yh, u_yl, v_xh, v_xl, u_th, u_tl, v_th, v_tl, d_th, d_tl, n1, n2, col_local, row_local, nv)

Arguments Type i/o Original arguments u_xh double i u_x(real(8)) u_xl double i u_x(real(8)) u_yh double i u_y(real(8)) u_yl double i u_y(real(8)) v_xh double i/o v_x(real(8)) v_xl double i/o v_x(real(8)) u_th double i u_t(real(8)) u_tl double i u_t(real(8)) v_th double i v_t(real(8)) v_tl double i v_t(real(8)) d_th double i d_t(real(8)) d_tl double i d_t(real(8)) n1 integer i n2 integer i col_local integer i row_local integer i nv integer i

Page 18: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

5

Routine name ddeigen_trd_Au_step3_sub1

Specification ddeigen_trd_Au_step3_sub1(v_xh, v_xl, v_th, v_tl, d_th, d_tl, u_yh, u_yl, n, nm1, nm2)

Arguments Type i/o Original arguments v_xh double i/o v_x(real(8)) v_xl double i/o v_x(real(8)) v_th double i v_t(real(8)) v_tl double i v_t(real(8)) d_th double i d_t(real(8)) d_tl double i d_t(real(8)) u_yl double i u_y(real(8)) u_yh double i u_y(real(8)) n integer i nm1 integer i nm2 integer i

Routine name ddeigen_trd_Au_step3_sub2

Specification ddeigen_trd_Au_step3_sub2(v_xh, v_xl, v_th, v_tl, d_th, d_tl, u_yh, u_yl, n, nm1, nm2)

Arguments Type i/o Original arguments v_xh double i/o v_x(real(8)) v_xl double i/o v_x(real(8)) v_th double i v_t(real(8)) v_tl double i v_t(real(8)) d_th double i d_t(real(8)) d_tl double i d_t(real(8)) u_yl double i u_y(real(8)) u_yh double i u_y(real(8)) n integer i nm1 integer i nm2 integer i

Routine name ddeigen_trd_Au_step3_sub3

Specification ddeigen_trd_Au_step3_sub2(v_xh, v_xl, v_th, v_tl, d_th, d_tl, u_yh, u_yl, n, nm1, nm2)

Arguments Type i/o Original arguments v_xh double i/o v_x(real(8)) v_xl double i/o v_x(real(8)) v_th double i v_t(real(8)) v_tl double i v_t(real(8)) d_th double i d_t(real(8)) d_tl double i d_t(real(8)) u_yl double i u_y(real(8)) u_yh double i u_y(real(8)) n integer i nm1 integer i nm2 integer i

Routine name ddeigen_trd_d_preserve

Page 19: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

6

Specification ddeigen_trd_d_preserve(ah, al, wh, wl, nm, d_th, d_tl, u_xh, u_xl, u_yh, u_yl, v_xh, v_xl, v_yh, v_yl, nv, m0, i_base, i_block)

Arguments Type i/o Original arguments ah double i/o a(real(8)) al double i/o a(real(8)) wh double o w(real(8)) wl double o w(real(8)) nm integer i d_th double o d_t(real(8)) d_tl double o d_t(real(8)) u_xh double i/o u_x(real(8)) u_xl double i/o u_x(real(8)) u_yh double i/o u_y(real(8)) u_yl double i/o u_y(real(8)) v_xh double i/o v_x(real(8)) v_xl double i/o v_x(real(8)) v_yh double i/o v_y(real(8)) v_yl double i/o v_y(real(8)) nv integer i m0 integer i i_base integer i i_block integer i

Routine name ddeigen_trd_2update

Specification ddeigen_trd_2update(arh, arl, nma, urh, url, uyrh, uyrl, vrh, vrl, nma, nmv, m_size, i_base)

Arguments Type i/o Original arguments arh double i/o ar(real(8)) arl double i/o ar(real(8)) nma integer i urh double i ur(real(8)) url double i ur(real(8)) uyrh double i uyr(real(8)) uyrl double i uyr(real(8)) vrh double i vr(real(8)) vrl double i vr(real(8)) vyrh double i vyr(real(8)) vyrl double i vyr(real(8)) nmv integer i m_size integer i i_base integer i

Routine name ddeigen_trd_2update_local

Specification ddeigen_trd_2update_local(wh, wl, nm, uxh, uxl, uyh, uyl, vxh, vxl, vyh, vyl, nv, i_base, i, ix)

Arguments Type i/o Original arguments wh double i/o w(real(8)) wl double i/o w(real(8)) nm integer i uxh double i ux(real(8)) uxl double i ux(real(8))

Page 20: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

7

uyh double i uy(real(8)) uyl double i uy(real(8)) vxh double i vx(real(8)) vxl double i vx(real(8)) vyh double i vy(real(8)) vyl double i vy(real(8)) i_base integer i i integer i ix integer i

Routine name ddeigen_trd_2update_local_special

Specification ddeigen_trd_2update_local_special(wh, wl, nm, uxh, uxl, uyh, uyl, vxh, vxl, vyh, vyl, nv, uxxh, uxxl, anorm2h, anorm2l, i_base, i)

Arguments Type i/o Original arguments wh double i/o w(real(8)) wl double i/o w(real(8)) nm integer i uxh double i ux(real(8)) uxl double i ux(real(8)) uyh double i uy(real(8)) uyl double i uy(real(8)) vxh double i vx(real(8)) vxl double i vx(real(8)) vyh double i vy(real(8)) vyl double i vy(real(8)) nm integer i uxxh double o uxx(real(8)) uxxl double o uxx(real(8)) anorm2h double o anorm2(real(8)) anorm2l double o anorm2(real(8)) i_base integer i i integer i

Routine name ddeigen_trd_2update_v

Specification ddeigen_trd_2update_v(u_xh, u_xl, v_xh, v_xl, uxh, uxl, vxh, vxl, nv, u_th, u_tl, v_th, v_tl, i, i_base, m0)

Arguments Type i/o Original arguments u_xh double i u_x(real(8)) u_xl double i u_x(real(8)) v_xh double o v_x(real(8)) v_xl double o v_x(real(8)) uxh double i ux(real(8)) uxl double i ux(real(8)) vxh double i vx(real(8)) vxl double i vx(real(8)) nv integer i u_th double i/o u_t(real(8)) u_tl double i/o u_t(real(8)) v_th double i/o v_t(real(8)) v_tl double i/o v_t(real(8)) i integer i

Page 21: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

8

i_base integer i m0 integer i

Routine name ddeigen_trd_u

Specification ddeigen_trd_u(ah, al, nm, u_xh, u_xl, u_yh, u_yl, n1, u_th, u_tl, v_th, v_tl, i, betah, betal, eh, el)

Arguments Type i/o Original arguments ah double i/o a(real(8)) al double i/o a(real(8)) nm integer i u_xh double i/o u_x(real(8)) u_xl double i/o u_x(real(8)) u_yh double i/o u_y(real(8)) u_yl double i/o u_y(real(8)) n1 integer i u_th double i/o u_t(real(8)) u_tl double i/o u_t(real(8)) v_th double i/o v_t(real(8)) v_tl double i/o v_t(real(8)) i integer i betah double i/o beta(real(8)) betal double i/o beta(real(8)) eh double o e(real(8)) el double o e(real(8))

Routine name ddeigen_trd_v

Specification ddeigen_trd_v(u_xh, u_xl, v_xh, v_xl, v_yh, v_yl, nv, u_th, u_tl, v_th, v_tl, betah, betal, i)

Arguments Type i/o Original arguments u_xh double i/o u_x(real(8)) u_xl double i/o u_x(real(8)) v_xh double i/o u_y(real(8)) v_xl double i/o u_y(real(8)) v_yh double i/o u_y(real(8)) v_yl double i/o u_y(real(8)) nv integer i u_th double i/o u_t(real(8)) u_tl double i/o u_t(real(8)) v_th double i/o v_t(real(8)) v_tl double i/o v_t(real(8)) betah double i/o beta(real(8)) betal double i/o beta(real(8)) i integer i

Routine name ddeigen_trd_d_restore Specification ddeigen_trd_d_restore(ah, al, wh, wl, nm, d_th, d_tl, m0, i_base) Arguments Type i/o Original arguments ah double i/o a(real(8)) al double i/o a(real(8)) wh double o w(real(8))

Page 22: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

9

wl double o w(real(8)) nm integer i d_th double o d_t(real(8)) d_tl double o d_t(real(8)) m0 integer i i_base integer i

Routine name ddeigen_dc

Function

Calculates the eigenvalues of an input matrix using the divide-and-conquer algorithm if the input matrix is a tridiagonal matrix obtained by HouseHolder tridiagonalization of a real symmetric matrix.

Specification ddeigen_dc(n, wh, wl, eh, el, zh, zl, ldz, info) Arguments

Descriptions i/o Original arguments

n Dimension of a matrix integer i wh High word of eigen values double o w(real(8)) wl Low word of eigen values double o w(real(8)) eh High word of eigen values double i e(real(8)) el Low word of eigen values double i e(real(8)) zh High word of eigen vectors double o z(real(8)) zl Low word of eigen vectors double o z(real(8)) ldz Size of array Z integer i info Error number integer o

Routine name ddeigen_tbk

Function Calculates the eigenvectors of the tridiagonal matrix obtained by HouseHolder tridiagonalization of a real symmetric matrix.

Specification ddeigen_tbk(n, ah, al, nma0, zh, zl, nmz0, eh, el, m0)

Arguments Descriptions i/o Original arguments

n Dimension of a matrix integer i

ah High word of quadruple precision real matrix

double i a (real(8))

al Low word of quadruple precision real matrix

double i a (real(8))

lda Size of array A integer i zh High word of eigen vectors double o z(real(8)) zl Low word of eigen vectors double o z(real(8)) ldz Size of array Z integer i eh High word of subdiagonal components double i e(real(8)) el Low word of subdiagonal components double i e(real(8)) m Blocking factor integer i

Routine name ddeigen_tbk_main1

Specification ddeigen_tbk_main1(n, ah, al, nma, zh, zl, nmz, eh, el, dh, dl, vh, vl, nm, m, ssh, ssl, tth, ttl)

Arguments Type i/o Original arguments n integer i

Page 23: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

10

ah double i a(real(8)) al double i a(real(8)) nma integer i zh double o z(real(8)) zl double o z(real(8)) nmz integer i eh double i e(real(8)) el double i e(real(8)) dh double o d(real(8)) dl double o d(real(8)) vh double o v(real(8)) vl double o v(real(8)) nm integer i m integer i ssh double o ss(real(8)) ssl double o ss(real(8)) tth double o tt(real(8)) ttl double o tt(real(8))

Routine name ddeigen_tbk_main2

Specification ddeigen_tbk_main2(n, zh, zl, nmz, dh, dl, vh, vl, nm, m, i, ssh, ssl, tth, ttl, dcom, dx, dy)

Arguments Type i/o Original arguments n integer i zh double o z(real(8)) zl double o z(real(8)) nmz integer i dh double i d(real(8)) dl double i d(real(8)) vh double i v(real(8)) vl double i v(real(8)) nm integer i m integer i i integer i ssh double i ss(real(8)) ssl double i ss(real(8)) tth double i tt(real(8)) ttl double i tt(real(8)) dcom double o dx double o dy double o

Routine name ddeigen_tbk_step1

Specification ddeigen_tbk_step1(zh, zl, nmz, vh, vl, nm, m, ssh, ssl, smh, sml, i_2, i_3, j_2, j_3)

Arguments Type i/o Original arguments zh double o z(real(8)) zl double o z(real(8)) nmz integer i vh double i v(real(8)) vl double i v(real(8))

Page 24: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

11

nm integer i m integer i ssh double i/o ss(real(8)) ssl double i/o ss(real(8)) smh double i/o sm(real(8)) sml double i/o sm(real(8)) i_2 integer i i_3 integer i j_2 integer i j_3 integer i

Routine name ddeigen_tbk_step2

Specification ddeigen_tbk_step2(zh, zl, nmz, vh, vl, nm, m, ssh, ssl, smh, sml, i_2, i_3, j_2, j_3)

Arguments Type i/o Original arguments zh double o z(real(8)) zl double o z(real(8)) nmz integer i vh double i v(real(8)) vl double i v(real(8)) nm integer i m integer i ssh double i/o ss(real(8)) ssl double i/o ss(real(8)) smh double i/o sm(real(8)) sml double i/o sm(real(8)) i_2 integer i i_3 integer i j_2 integer i j_3 integer i

Routine name ddisend_dbl Specification ddisend_dbl(bufh, bufl, n, idest, ireq, icom) Arguments Type i/o Original arguments bufh double i/o buf(real(8)) bufl double i/o buf(real(8)) n integer i idest integer i ireq integer i icom integer i

Routine name ddrecv_dbl Specification ddrecv_dbl(bufh, bufl, n, isrc, icom) Arguments Type i/o Original arguments bufh double i/o buf(real(8)) bufl double i/o buf(real(8)) n integer i isrc integer i icom integer i

Page 25: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

12

Routine name ddirecv_dbl Specification ddirecv_dbl(bufall, n, isrc, ireq, icom) Arguments Type i/o Original arguments bufall double i/o buf(real(8)) n integer i isrc integer i ireq integer i icom integer i

Routine name ddbcast_dbl Specification ddbcast_dbl(bufh, bufl, n, iroot, icom) Arguments Type i/o Original arguments bufh double i/o buf(real(8)) bufl double i/o buf(real(8)) n integer i iroot integer i icom integer i

Routine name ddreduce_dbl Specification ddreduce_dbl(bufh, bufl, wrkh, wrkl, n, dist, icom) Arguments Type i/o Original arguments bufh double i/o buf(real(8)) bufl double i/o buf(real(8)) wrkh double i/o wrk(real(8)) wrkl double i/o wrk(real(8)) n integer i dist integer i icom integer i

Routine name dddatacast_dbl Specification dddatacast_dbl(u_yh, u_yl, u_xh, u_xl, u_th, u_tl, u_sh, u_sl, n) Arguments Type i/o Original arguments u_yh double i/o u_y(real(8)) u_yl double i/o u_y(real(8)) u_xh double i/o u_x(real(8)) u_xl double i/o u_x(real(8)) u_th double i/o u_t(real(8)) u_tl double i/o u_t(real(8)) u_sh double i/o u_s(real(8)) u_sl double i/o u_s(real(8)) n integer i

The followings are subroutines of DDScaLAPACK called from ddeigen.

Routine name pddstedc

Function Parallel computing eigen values and eigen vectors of tridiagonal matrix by divide and conquer method.

Specification pddstedc(COMPZ, N, Dh, Dl, Eh, El, Qh, Ql, IQ, JQ, DESCQ, WORKh, WORKl, LWORK, IWORK, LIWORK, INFO)

Page 26: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

13

Arguments Descriptions i/o Original arguments

COMPZ

Options for calculations N: eigen values I: eigen values and eigen vectors oftridiagonal matrix V: eigen values and eigen vectors of

original symmetric / hermitian matrix

character*1 i

N Order of a symmetric tridiagonal matrix

integer i

Dh High word of diagonal components of a tridiagonal matrix

double i/o D (real(8))

Dl Low word of diagonal components of a tridiagonal matrix

double i/o D (real(8))

Eh High word of subdiagonal components of a tridiagonal matrix

double i/o E (real(8))

El Low word of subdiagonal components of a tridiagonal matrix

double i/o E (real(8))

Qh

High word of the orthogonal quadruple precision real matrix used to reduce the full matrix to tridiagonal form

double i Q (real(8))

Ql

Low word of the orthogonal quadruple precision real matrix used to reduce the full matrix to tridiagonal form

double i Q (real(8))

IQ Row index of a matrix integer i JQ Column index of a matrix Q integer i DESCQ integer i WORKh High word of an array for workspace double i WORK (real(8)) WORKl Low word of an array for workspace double i WORK (real(8)) LWORK Dimension of the array WORK integer i IWORK Array for workspace integer o e(real(8)) LIWORK Size of workspace integer o e(real(8)) INFO Information flag integer o

Routine name ddlapst Function Sort numbers by ascending or descending order Specification ddlapst(ID, N, Dh, Dl, INDX, INFO) Arguments

Descriptions i/o Original arguments

ID Type of sorting character*1 i N Size of an array to sort integer i Dh High word of a sorting array double i/o D (real(8)) Dl Low word of a sorting array double i/o D (real(8)) INDX Index spliting an array D integer o INFO Information flag integer o

Routine name pddlaed0 Function Computes all eigenvalues and corresponding eigenvectors of an

Page 27: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

14

unreduced symmetric tridiagonal matrix using the divide and conquer method

Specification pddlaed0(COMPZ, N, Dh, Dl, Eh, El, Qh, Ql, IQ, JQ, DESCQ, WORKh, WORKl, LWORK, IWORK, LIWORK, INFO)

Arguments Descriptions i/o Original arguments

COMPZ

Options for calculation N: Compute eigenvalues only. I: Compute eigenvectors of original dense symmetric matrix also. V: Compute eigenvalues and eigenvectors of tridiagonal matrix.

character*1 i

N Order of a symmetric tridiagonal matrix

integer i

Dh High word of diagonal components of a tridiagonal matrix

double i/o D (real(8))

Dl Low word of diagonal components of a tridiagonal matrix

double i/o D (real(8))

Eh High word of subdiagonal components of a tridiagonal matrix

double i/o E (real(8))

El Low word of subdiagonal components of a tridiagonal matrix

double i/o E (real(8))

Qh

High word of the orthogonal quadruple precision real matrix used to reduce the full matrix to tridiagonal form

double i Q (real(8))

Ql

Low word of the orthogonal quadruple precision real matrix used to reduce the full matrix to tridiagonal form

double i Q (real(8))

IQ Row index of a matrix Q integer i JQ Column index of a matrix Q integer i DESCQ integer i WORKh High word of an array for workspace double i WORK (real(8)) WORKl Low word of an array for workspace double i WORK (real(8)) LWORK Dimension of the array WORK integer i IWORK Array for workspace integer o e(real(8)) LIWORK Size of workspace integer o e(real(8)) INFO Information flag integer o

Routine name pddlaed1

Function Computes parallel the updated eigensystem of a diagonal matrix after modification by a rank-one symmetric matrix. Used when the original matrix is tridiagonal

Specification DDLAED1( N, N1, Dh, Dl, ID, Qh, Ql, IQ, JQ, DESCQ, RHOh, RHOl, WORKh, WORKl, IWORK, INFO)

Arguments

Descriptions i/o Original arguments

N Order of a symmetric tridiagonal matrix integer i N1 The position index of eigen value integer i Dh High word of the eigenvalues of the double i/o D (real(8))

Page 28: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

15

rank-1-perturbed matrix

Dl Low word of the eigenvalues of the rank-1-perturbed matrix

double i/o D (real(8))

ID The first index to compute an eigen value

integer i

Qh High word of the eigenvectors of the rank-1-perturbed matrix

double i/o Q (real(8))

Ql Low word of the eigenvectors of the rank-1-perturbed matrix

double i/o Q (real(8))

IQ Row size of a matrix Q integer i JQ Column size of a matrix Q integer i

DESCQ The permutation which separately sorts the two sub-problems

integer i

RHOh High word of subdiagonal components used to create the rank-1 modification

double RHO (real(8))

RHOl Low word of subdiagonal components used to create the rank-1 modification

double RHO (real(8))

WORKh High word of an array for workspace double WORK (real(8)) WORKl Low word of an array for workspace double WORK (real(8)) IWORK Array for workspace integer i INFO Information flag integer o

Routine name pddlaed2 Function Merges eigenvalues and deflates secular equation

Specification

PDDLAED2(ICTXT, K, N, N1, NB, Dh, Dl, DROW, DCOL, Qh, Ql, LDQ, RHOh, RHOl, Zh, Zl, Wh, Wl, DLAMDAh, DLAMDAl, Q2h, Q2l, LDQ2, QBUFh, QBUFl, CTOT, PSM, NPCOL, INDX, INDXC, INDXP, INDCOL, COLTYP, NN, NN1, NN2, IB1, IB2)

Arguments Descriptions i/o Original arguments

NPCOL Total row size integer i INDX Array for workspace integer INDXC Array for workspace integer INDXP Array for workspace integer COLTYP Array for workspace integer i NN Dimension of a matrix U integer i NN1 Dimension of a matrix Q1 integer i NN2 Dimension of a matrix Q2 integer i IB1 Pointer index of a matrix Q1 integer i IB2 Pointer index of a matrix Q2 integer i

Routine name pddlaed3 Function Find roots of the secular equation and update eigen vectors

Specification PDDLAED3(ICTXT, K, N, NB, Dh, Dl, DROW, DCOL, RHOh, RHOl, DLAMDAh,DLAMDAl, Wh, Wl, Zh, Zl, Uh, Ul, LDU, BUFh, BUFl, INDX, INDCOL, INDROW, INDXR, INDXC, CTOT, NPCOL, INFO )

Arguments Descriptions i/o Original arguments

ICTXT Index for BLACS integer i

K The number of items of rational functions solving in laed4

integer i

Page 29: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

16

N Dimenstion of a symmetric tridiagonal matrix

integer i

NB Blocking factor integer i

Dh High word of diagonal components of a tridiagonal matrix

double o D (real(8))

Dl Low word of diagonal components of a tridiagonal matrix

double o D (real(8))

DROW Row size of a matrix D integer i DCOL Column size of a matrix D integer i Qh High word of an array Q double i Q (real(8)) Ql Low word of an array Q double i Q (real(8)) LDQ The first dimension of an array Q integer i

RHOh High word of the parameter of rank 1 update equation

double i RHO (real(8))

RHOl Low word of the parameter of rank 1 update equation

double i RHO (real(8))

DLAMDAh High word of original roots of update problem contracted with the first K components

double i DLAMDA (real(8))

DLAMDAl Low word of original roots of update problem contracted with the first K components

double i DLAMDA (real(8))

Wh High word of update vector components for contraction adjustment

double i W (real(8))

Wl Low word of update vector components for contraction adjustment

double i W (real(8))

Zh High word of components of the update vector

double i Z (real(8))

Zl Low word of components of the update vector

double i Z (real(8))

Uh High word of components of the update vector

double i U (real(8))

Ul Low word of components of the update vector

double i U (real(8))

INDX Array for workspace integer i INDCOL Array for workspace integer i INDXR Array for workspace integer i INDXC Array for workspace integer i CTOT Array for workspace integer i NPCOL The number of total columns integer i INFO Information flag integer o

Routine name pddlaedz Function

Specification PDDLAEDZ( N, N1, ID, Qh, Ql, IQ, JQ, LDQ, DESCQ, Zh, Zl, WORKh, WORKl )

Arguments Descriptions i/o Original arguments

N Order of a symmetric tridiagonal matrix

integer i

N1 Pointer of the last eigen value in the first submatrix

integer i

Page 30: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

17

ID The first index to compute an eigen vector

integer i

Qh High word of the eigenvectors of the rank-1-perturbed matrix

double i/o Q (real(8))

Ql Low word of the eigenvectors of the rank-1-perturbed matrix

double i/o Q (real(8))

IQ Row size of a matrix Q integer i JQ Column size of a matrix Q integer i

DESCQ The permutation which separately sorts the two sub-problems

integer i

Zh High word of components of the update vector

double i Z (real(8))

Zl Low word of components of the update vector

double i Z (real(8))

WORKh High word of an array for workspace double i WORK (real(8)) WORKl Low word of an array for workspace double i WORK (real(8))

Routine name pddlamch Function Compute the machine parameter of floating point arithmetics Specification pddlamch(ICTXT, CMACH, DDPh, DDPl)

Arguments Descriptions i/o Original arguments

ICTXT Index for BLACS integer i CMACH Option for the return value character i DDPh High word of the return value double i/o DDPl Low word of the return value double i/o

Routine name pddlase2

Function Initialize off-diagonal and diagonal components of a matrix by specified values

Specification PDDLASE2( UPLO, M, N, ALPHAh, ALPHAl, BETAh, BETAl, Ah, Al, IA, JA, DESCA )

Arguments

Descriptions i/o Original arguments

UPLO

Option of calculation U : upper trianglular components of a matrix A L : lower triangular components of a matrix A other : all components of a matrix A

character*1 i

M Row size of a matrix A integer i N Column size of a matrix A integer i ALPHAh 非 High word of diagonal components double i/o D (real(8)) ALPHAl 非 Low word of diagonal components double i/o D (real(8)) BETAh High word of diagonal components double i/o E (real(8)) BETAl Low word of diagonal components double i/o E (real(8)) Ah High word of the multiplicand matrix double i/o A (real(8)) Al Low word of the multiplicand matrix double i/o A (real(8)) IA Row size of an array A integer i JA Column size of an array A integer i DESCA Size of array A integer i

Page 31: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

18

Routine name pddlaset

Function Initialize off-diagonal and diagonal components of a matrix by specified values

Specification PDDLASET( UPLO, M, N, ALPHAh, ALPHAl, BETAh, BETAl, Ah, Al, IA, JA, DESCA )

Arguments Descriptions i/o Original arguments

UPLO

Option of calculation U : upper trianglular components of a matrix A L : lower triangular components of a matrix A other : all components of a matrix A

character i

M Row size of a matrix A integer i N Column size of a matrix A integer i ALPHAh 非 High word of diagonal components double i/o D (real(8)) ALPHAl 非 Low word of diagonal components double i/o D (real(8)) BETAh High word of diagonal components double i/o E (real(8)) BETAl Low word of diagonal components double i/o E (real(8))

Ah High word of the multiplicand matrix

double i/o A (real(8))

Al Low word of the multiplicand matrix double i/o A (real(8)) IA Row size of an array A integer i JA Column size of an array A integer i DESCA Size of array A integer i

Routine name pddlasrt Function Sort matrices D and Q

Specification PDDLASRT( ID, N, Dh, Dl, Qh, Ql, IQ, JQ, DESCQ, WORKh, WORKl, LWORK, IWORK, LIWORK, INFO )

Arguments Descriptions i/o Original arguments

ID Type of sorting character i N Size of an array to sort integer i Dh High word of a sorting array double i/o D (real(8)) Dl Low word of a sorting array double i/o D (real(8)) Qh High word of a vector to sort double i/o Q (real(8)) Ql Low word of a vector to sort double i/o Q (real(8)) IQ Row index of a matrix integer i JQ Column index of a matrix Q integer i DESCQ Size of an array Q integer i WORKh High word of an array for workspace double i WORK (real(8)) WORKl Low word of an array for workspace double i WORK (real(8)) LWORK Dimension of the array WORK integer i IWORK Array for workspace integer o LIWORK Size of workspace integer o INFO Information flag integer o

Routine name pddgemr2d

Page 32: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

19

Function Copy from a matrix A to a matrix B Specification pddgemr2d(M, N, Ah, Al, IA, JA, ADESC, Bh, Bl, IB, JB, BDESC, CTXT) Arguments

Descriptions i/o Original arguments

M Row size of a matrix A integer i N Column size of a matrix A integer i

Ah High word of the array A stored M x N matrix

double i A (real(8))

Al Low word of the array A stored M x N matrix double i A (real(8)) IA Column size of a matrix A integer i JA Row size of a matrix A integer i ADESC Size of array A integer i

Bh High word of the array B stored M x N matrix

double o B (real(8))

Bl High word of the array B stored M x N matrix

double o B (real(8))

IB Column size of a matrix B integer i JB Row size of a matrix B integer i BDESC Size of a array B integer i CTXT The number of processors integer i

The followings are the DDLAPACK subroutines called by DDEigen_s.

Routine name ddstedc

Function Computes all eigenvalues and, optionally, eigenvectors of a symmetric tridiagonal matrix using the divide and conquer method

Specification ddstedc(COMPZ, N, Dh, Dl, Eh, El, Qh, Ql, IQ, JQ, DESCQ, WORKh, WORKl, LWORK, IWORK, LIWORK, INFO)

Arguments

Descriptions i/o Original arguments

COMPZ

Options for calculation N : Compute eigenvalues only I : Compute eigenvectors of tridiagonal matrix also V : Compute eigenvectors of original Hermitian matrix also

character

i

N Order of a symmetric tridiagonal matrix integer i

Dh High word of diagonal components of a tridiagonal matrix

double i/o D (real(8))

Dl Low word of diagonal components of a tridiagonal matrix

double i/o D (real(8))

Eh High word of subdiagonal components of a tridiagonal matrix

double i/o E (real(8))

El Low word of subdiagonal components of a tridiagonal matrix

double i/o E (real(8))

Zh High word of the orthogonal quadruple precision real matrix used to reduce the full matrix to tridiagonal form

double i Q (real(8))

Zl Low word of the orthogonal quadruple precision real matrix used to reduce the full matrix to tridiagonal form

double i Q (real(8))

Page 33: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

20

LDZ Row index of a matrix integer i WORKh High word of an array for workspace double i WORK (real(8)) WORKl Low word of an array for workspace double i WORK (real(8)) LWORK The dimension of the array WORK integer i IWORK Array for workspace integer o e(real(8)) LIWORK Size of workspace integer o e(real(8)) INFO Information flag integer o

Routine name ddisnan Function Judge whether an argument is NaN or not Specification ddisnan(DINh, DINl) Arguments

Descriptions i/o Original arguments

DINh High word of argument for test double i DIN (real(8)) DINl Low word of argument for test double i DIN (real(8))

Routine name ddlacpy Function Copy all or part of one two-dimensional array to another Specification ddstedc(UPLO, M, N, Ah, Al, lda, Bh, Bl ldb) Arguments

Descriptions i/o Original arguments

UPLO

Options for copy U : copy upper triangular components of A J : copy lower triangular components of A

character

i

M Row size of a matrix A integer i N Column size of a matrix A integer i

Ah High word of the array A stored M x N matrix

double i A (real(8))

Al Low word of the array A stored M x N matrix double i A (real(8)) lda Size of a matrix A integer i

Bh High word of the array B stored M x N matrix

double o B (real(8))

Bl Low word of the array B stored M x N matrix double o B (real(8)) ldb Size of a matrix B integer i

Routine name ddlaed0

Function Computes all eigenvalues and corresponding eigenvectors of an unreduced symmetric tridiagonal matrix using the divide and conquer method

Specification ddlaed0(ICOMPQ, QSIZ, N, Dh, Dl, Eh, El, Qh, Ql, LDQ, QSTOREh, QSTOREl, LDQS, WORKh, WORKl, IWORK, INFO)

Arguments

Descriptions i/o Original arguments

ICPMPQ

Options for computation 0: Compute eigenvalues only. 1: Compute eigenvectors of original dense symmetric matrix also. 2: Compute eigenvalues and eigenvectors of tridiagonal matrix

integer i

Page 34: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

21

QSIZ The dimenstion of the orthogonal matrix used to reduce the full matrix to tridiagonal form

integer i

N Order of a symmetric tridiagonal matrix integer i

Dh High word of diagonal components of a tridiagonal matrix

double i/o D (real(8))

Dl Low word of diagonal components of a tridiagonal matrix

double i/o D (real(8))

Eh High word of subdiagonal components of a tridiagonal matrix

double i/o E (real(8))

El Low word of subdiagonal components of a tridiagonal matrix

double i/o E (real(8))

Qh High word of the orthogonal quadruple precision real matrix used to reduce the full matrix to tridiagonal form

double i Q (real(8))

Ql Low word of the orthogonal quadruple precision real matrix used to reduce the full matrix to tridiagonal form

double i Q (real(8))

LDQ The leading dimension of the array Q integer i QSTOREh High word of an array for workspace double QSTORE (real(8)) QSTOREl Low word of an array for workspace double QSTORE (real(8))

LDQS The leading dimension of the array QSTORE

integer i

WORKh High word of an array for workspace double WORK (real(8)) WORKl Low word of an array for workspace double WORK (real(8)) IWORK Array for workspace integer i INFO Information flag integer o

Routine name ddlaed1

Function Computes the updated eigensystem of a diagonal matrix after modification by a rank-one symmetric matrix

Specification ddlaed1(N, Dh, Dl, Qh, Ql, LDQ, INDXQ, RHOh, RHOl, CUTPNT, WORKh, WORKl, IWORK, INFO)

Arguments

Descriptions i/o Original arguments

N Order of a symmetric tridiagonal matrix integer i

Dh High word of the eigenvalues of the rank-1-perturbed matrix

double i/o D (real(8))

Dl Low word of the eigenvalues of the rank-1-perturbed matrix

double i/o D (real(8))

Qh High word of the eigenvectors of the rank-1-perturbed matrix

double i/o Q (real(8))

Ql Low word of the eigenvectors of the rank-1-perturbed matrix

double i/o Q (real(8))

LDQ The leading dimension of the array Q integer i

INDXQ The permutation which separately sorts the two sub-problems

integer i

RHOh High word of subdiagonal components used to create the rank-1 modification

double i RHO (real(8))

RHOl Low word of subdiagonal components used to create the rank-1 modification

double i RHO (real(8))

CUTPNT Pointer of the last eigen value in the integer i

Page 35: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

22

first submatrix WORKh High word of an array for workspace double i WORK (real(8)) WORKl Low word of an array for workspace double i WORK (real(8)) IWORK Array for workspace integer i INFO Information flag integer o

Routine name ddlaed2 Function Merges eigenvalues and deflates secular equation

Specification ddlaed2(K, N, N1, Dh, Dl, Qh, Ql, LDQ, INDXQ, RHOh, RHOl, Zh, Zl, DLAMDAh, DLAMDAl, Wh, Wl, Q2h, Q2l, INDX, INDXC, INDXP, COLTYP, INFO)

Arguments

Descriptions i/o Original arguments

K The number of non-deflated eigenvalues integer i N Order of a symmetric tridiagonal matrix integer i

N1 Pointer of the last eigen value in the first submatrix

integer i

Dh High word of the eigenvalues of the two submatrices to be combined

double i/o D (real(8))

Dl Low word of the eigenvalues of the two submatrices to be combined

double i/o D (real(8))

Qh High word of the eigenvectors of two submatrices in the two square blocks

double i/o Q (real(8))

Ql Low word of the eigenvectors of two submatrices in the two square blocks

double i/o Q (real(8))

LDQ The leading dimension of the array Q integer i

INDXQ The permutation which separately sorts the two sub-problems

integer i

RHOh

High word of the offdiagonal components associated with the rank-1 cut which originally split the two submatrices now recombined

double i RHO (real(8))

RHOl

Low word of the offdiagonal components associated with the rank-1 cut which originally split the two submatrices now recombined

double i RHO (real(8))

Zh High word of an array of update vector double i Z (real(8)) Zl Low word of an array of update vector double i Z (real(8))

DLAMDAh High word of a copy of the first k eigen values

double o DLAMDA (real(8))

DLAMDAl Low word of a copy of the first k eigen values

double o DLAMDA (real(8))

Wh High word of an array of the first k components of the final reduced update Z vector

double o W (real(8))

Wl Low word of an array of the first k components of the final reduced update Z vector

double o W (real(8))

Q2h High word of an array stored a copy of the first k-th eigen vectors

double o Q2 (real(8))

Q2l Low word of an array stored a copy of the first k-th eigen vectors

double o Q2 (real(8))

INDX Array for workspace integer i

Page 36: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

23

INDXC Array for workspace integer i INDXP Array for workspace integer i COLTYP Array for workspace integer i INFO Information flag integer o

Routine name ddlaed3 Function Find roots of the secular equation and update eigen vectors

Specification ddlaed3(K, N, N1, Dh, Dl, Qh, Ql, LDQ, RHOh, RHOl, DLAMDAh, DLAMDAl, Q2h, Q2l, INDX, CTOT, Wh, Wl, Sh, Sl, INFO)

Arguments

Descriptions i/o Original arguments

K The number of items of rational functions solving in laed4

integer i

N Size of a matrix Q integer i

N1 Pointer of the last eigen value in the first submatrix

integer i

Dh High word of diagonal components of a tridiagonal matrix

double o D (real(8))

Dl Low word of diagonal components of a tridiagonal matrix

double o D (real(8))

Qh High word of an array Q double i Q (real(8)) Ql Low word of an array Q double i Q (real(8)) LDQ The first dimension of an array Q integer i

RHOh High word of the parameter of rank 1 update equation

double i RHO (real(8))

RHOl Low word of the parameter of rank 1 update equation

double i RHO (real(8))

DLAMDAh High word of original roots of update problem contracted with the first K components

double i DLAMDA (real(8))

DLAMDAl Low word of original roots of update problem contracted with the first K components

double i DLAMDA (real(8))

Q2h High word of an array of unreduced eigen vector for dividing problem

double i Q2 (real(8))

Q2l Low word of an array of unreduced eigen vector for dividing problem

double i Q2 (real(8))

INDX Array for workspace integer i CTOT Array for workspace integer i

Sh High word of accumulated eigen vectors for updating system of equations

double i S (real(8))

Sl Low word of accumulated eigen vectors for updating system of equations

double i S (real(8))

Wh High word of update vector components for contraction adjustment

double i W (real(8))

Wl Low word of update vector components for contraction adjustment

double i W (real(8))

INFO Information flag integer o

Routine name ddlaed4 Function Find the unique root of the secular equation

Page 37: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

24

Specification ddstedc(N, I, Dh, Dl, Zh, Zl, DELTAh, DELTAl, RHOh, RHOl, DLAMh, DLAMl, INFO)

Arguments

Descriptions i/o Original arguments

N Size of an total array integer i I Index of calculating eigen value integer i Dh High word of the original eigen value double i D (real(8)) Dl Low word of the original eigen value double i D (real(8))

Zh High word of components of update vector Z

double i Z (real(8))

Zl Low word of components of update vector Z

double i Z (real(8))

DELTAh High word of D(J)-LAMBDA double o DELTA (real(8)) DELTAl Low word of D(J)-LAMBDA double o DELTA (real(8))

RHOh High word of a scalar of update symmetric formula

double i RHO (real(8))

RHOl Low word of a scalar of update symmetric formula

double i RHO (real(8))

DLAMh High word of th i-th calculated eigen value

double o DLAM (real(8))

DLAMl Low word of th i-th calculated eigen value

double o DLAM (real(8))

INFO Information flag integer o

Routine name ddlaed5 Function Solve the secular equation of 2 x 2

Specification dlaed5(I, Dh, Dl, Zh, Zl, DELTAh, DELTAl, RHOh, RHOl, DLAMh, DLAMl, INFO)

Arguments

Descriptions i/o Original arguments

I Index of calculating eigen value integer i Dh High word of the original eigen value double i D (real(8)) Dl Low word of the original eigen value double i D (real(8))

Zh High word of components of update vector Z

double i Z (real(8))

Zl Low word of components of update vector Z

double i Z (real(8))

DELTAh High word of the information for constructing eigen vectors

double o DELTA (real(8))

DELTAl Low word of the information for constructing eigen vectors

double o DELTA (real(8))

RHOh High word of a scalar of update symmetric formula

double i RHO (real(8))

RHOl Low word of a scalar of update symmetric formula

double i RHO (real(8))

DLAMh High word of th i-th calculated eigen value

double o DLAM (real(8))

DLAMl Low word of th i-th calculated eigen value

double o DLAM (real(8))

INFO Information flag integer o

Page 38: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

25

Routine name ddlaed6 Function Calculate one of Newton steps of solutions of the secular equations

Specification ddlaed6(KNITER, ORGATI,RHOh, RHOl, Dh, Dl, Zh, Zl, FINITh, FINITl, TAUh, TAUl, INFO)

Arguments

Descriptions i/o Original arguments

KNITER Size of an array integer i

ORGATI If true, there exists a root between D(2) and D(3)

integer i

Dh High word of an array satisfying D(1) < D(2) <D(3)

double i/o D (real(8))

Dl Low word of an array satisfying D(1) < D(2) <D(3)

double i/o D (real(8))

Zh Array for workspace double i Z (real(8)) Zl Array for workspace double i Z (real(8)) FINITh High word of the value of f(x) at 0 double i FINIT (real(8)) FINITl Low word of the value of f(x) at 0 double i FINIT (real(8)) TAUh High word of roots of f(x) double o WORK (real(8)) TAUl Low word of roots of f(x) double o WORK (real(8)) INFO Information flag integer o

Routine name ddlaed7

Function Computes the updated eigensystem of a diagonal matrix after modification by a rank-one symmetric matrix

Specification DDLAED7( ICOMPQ, N, QSIZ, TLVLS, CURLVL, CURPBM, Dh, Dl, Qh, Ql, LDQ, INDXQ, RHOh, RHOl, CUTPNT, QSTOREh, QSTOREl, QPTR, PRMPTR, PERM, GIVPTR, GIVCOL, GIVNUMh, GIVNUMl, WORKh, WORKl, IWORK, INFO )

Arguments

Descriptions i/o Original arguments

ICOMPQ Options for calculation 0 : calculate eigen values

integer i

N Order of a symmetric tridiagonal matrix integer i

QSIZ Dimension of the orthogonal matrix used to reduce to tridiagonal form

integer i

TLVLS Sum of levels of integration in all divide and conquer tree

integer i

CURLVL Current level for integration routines integer i

CURPBM Current problem of current level for integration routines

integer i

Dh High word of an eigen value of a rank 1 permutation matrix

double i/o D (real(8))

Dl Low word of an eigen value of a rank 1 permutation matrix

double i/o D (real(8))

Qh High word of eigen vectors of a rank 1 permutation matrix

double i/o Q (real(8))

Ql Low word of eigen vectors of a rank 1 permutation matrix

double i/o Q (real(8))

LDQ The first dimension of an array Q integer i INDXQ The first dimension of an array Q integer i

RHOh High word of sub diagonal components for generating rank 1 update

double i RHO (real(8))

RHOl Low word of sub diagonal components for double i RHO (real(8))

Page 39: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

26

generating rank 1 update

CUTPNT Pointer of the last eigen value in the first submatrix

integer i

QSTOREh High word of an compressed array of eigen vectors of submatrices in divide-conquer process

double i QSTORE (real(8))

QSTOREl Low word of an compressed array of eigen vectors of submatrices in divide-conquer process

double i QSTORE (real(8))

QPTR List of beginnig indices for submatrices stored QSTORE

integer i

PRMPTR List of pointers for some level of permutations in PERM

integer i

PERM Permutations on each eigen block integer i

GIVPTR List of pointers in storage of GIVCOL for some levels of Givens rotation

integer i

GIVCOL Pair of columns for Givens rotation integer i

GIVNUMh High word of parameter S of Givens rotation

double i GIVNUM (real(8))

GIVNUMl Low word of parameter S of Givens rotation

double i GIVNUM (real(8))

WORKh High word of an array for workspace double i WORK (real(8)) WORKl Low word of an array for workspace double i WORK (real(8)) IWORK Array for workspace integer o INFO Information flag integer o

Routine name ddlaed8 Function Merges eigenvalues and deflates secular equation

Specification DDLAED8( ICOMPQ, K, N, QSIZ, Dh, Dl, Qh, Ql, LDQ, INDXQ, RHOh, RHOl, CUTPNT, Zh, Zl, DLAMDAh, DLAMDAl, Q2h, Q2l, LDQ2, Wh, Wl, PERM, GIVPTR, GIVCOL, GIVNUMh, GIVNUMl, INDXP, INDX, INFO )

Arguments

Descriptions i/o Original arguments

ICOMPQ Options for calculation 0 : calculate eigen values

integer i

K Order of a symmetric tridiagonal matrix integer i N Order of a symmetric tridiagonal matrix integer i

QSIZ Dimension of the orthogonal matrix used to reduce to tridiagonal form

integer i

Dh High word of an eigen value of a rank 1 permutation matrix

double i/o D (real(8))

Dl Low word of an eigen value of a rank 1 permutation matrix

double i/o D (real(8))

Qh High word of eigen vectors of a rank 1 permutation matrix

double i/o Q (real(8))

Ql Low word of eigen vectors of a rank 1 permutation matrix

double i/o Q (real(8))

LDQ The first dimension of an array Q integer i INDXQ The first dimension of an array Q integer i

RHOh High word of sub diagonal components for generating rank 1 update

double i RHO (real(8))

RHOl Low word of sub diagonal components for double i RHO (real(8))

Page 40: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

27

generating rank 1 update

CUTPNT Pointer of the last eigen value in the first submatrix

integer i

QSTOREh High word of an compressed array of eigen vectors of submatrices in divide-conquer process

double i QSTORE (real(8))

QSTOREl Low word of an compressed array of eigen vectors of submatrices in divide-conquer process

double i QSTORE (real(8))

QPTR List of beginnig indices for submatrices stored QSTORE

integer i

PRMPTR List of pointers for some level of permutations in PERM

integer i

PERM Permutations on each eigen block integer i

GIVPTR List of pointers in storage of GIVCOL for some levels of Givens rotation

integer i

GIVCOL Pair of columns for Givens rotation integer i

GIVNUMh High word of parameter S of Givens rotation

double i GIVNUM (real(8))

GIVNUMl Low word of parameter S of Givens rotation

double i GIVNUM (real(8))

INDXP Array for workspace integer o INDX Array for workspace integer o INFO Information flag integer o

Routine name ddlaed9 Function Find roots of the secular equation and update eigen vectors

Specification DDLAED9( K, KSTART, KSTOP, N, Dh, Dl, Qh, Ql, LDQ, RHOh, RHOl, DLAMDAh, DLAMDAl, Wh, Wl, Sh, Sl, LDS, INFO )

Arguments

Descriptions i/o Original arguments

K The number of items of rational functions solving in laed4

integer i

KSTART Range of update eigen values integer i KSTOP Range of update eigen values integer i N Size of a matrix Q integer i Dh High word of updated eigen values double o D (real(8)) Dl Low word of updated eigen values double o D (real(8)) Qh High word of an array Q double i Q (real(8)) Ql Low word of an array Q double i Q (real(8)) LDQ The first dimension of an array Q integer i

RHOh High word of the parameter of rank 1 update equation

double i RHO (real(8))

RHOl Low word of the parameter of rank 1 update equation

double i RHO (real(8))

DLAMDAh High word of original roots of update problem contracted with the first K components

double i DLAMDA (real(8))

DLAMDAl Low word of original roots of update problem contracted with the first K components

double i DLAMDA (real(8))

Wh High word of update vector components double i W (real(8))

Page 41: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

28

for contraction adjustment

Wl Low word of update vector components for contraction adjustment

double i W (real(8))

Sh High word of accumulated eigen vectors for updating system of equations

double i S (real(8))

Sl Low word of accumulated eigen vectors for updating system of equations

double i S (real(8))

LDS The first dimension of an array S integer i INFO Information flag integer o

Routine name ddlaeda Function Calculate Z vector defining rank 1 update summetric matrix

Specification DDLAEDA( N, TLVLS, CURLVL, CURPBM, PRMPTR, PERM,GIVPTR, GIVCOL, GIVNUMh, GIVNUMl, Qh, Ql, QPTR, Zh, Zl, ZTEMPh, ZTEMPl, INFO )

Arguments

Descriptions i/o Original arguments

N Order of a symmetric tridiagonal matrix integer i

TLVLS Sum of levels of integration in all divide and conquer tree

integer i

CURLVL Current level for integration routines integer i

CURPBM Current problem of current level for integration routines

integer i

GIVPTR List of pointers in storage of GIVCOL for some levels of Givens rotation

integer i

GIVCOL Pair of columns for Givens rotation integer i

GIVNUMh High word of parameter S of Givens rotation

double i GIVNUM (real(8))

GIVNUMl Low word of parameter S of Givens rotation

double i GIVNUM (real(8))

Qh High word of eigen vectors of a rank 1 permutation matrix

double i/o Q (real(8))

Ql Low word of eigen vectors of a rank 1 permutation matrix

double i/o Q (real(8))

QPTR List of beginnig indices for submatrices stored QSTORE

integer i

Zh High word of components of update vector Z

double o Z (real(8))

Zl Low word of components of update vector Z

double o Z (real(8))

ZTEMPh Array for workspace double i ZTENP (real(8)) ZTEMPl Array for workspace double i ZTEMP (real(8)) INFO Information flag integer o

Routine name ddlaev2

Function Calculate eigen values and eigen vectors of symmetric matrix of degree 2

Specification ddlaev2(Ah, Al, Bh, Bl, Ch, Cl, RT1h, RT1l, RT2h, RT2l, CS1h, CS1l, SN1h, SN1l)

Arguments

Descriptions i/o Original arguments

Ah High word of input matrix components double i/o A (real(8))

Page 42: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

29

Al Low word of input matrix components double i/o A (real(8)) Bh High word of input matrix components double i/o B (real(8)) Bl Low word of input matrix components double i/o B (real(8)) Ch High word of input matrix components double i/o C (real(8)) Cl Low word of input matrix components double i/o C (real(8)) RT1h High word of a larger eigen value double i/o RT1 (real(8)) RT1l Low word of a larger eigen value double i/o RT1 (real(8)) RT2h High word of a smaller eigen value double i/o RT2 (real(8)) RT2l Low word of a smaller eigen value double i/o RT2 (real(8)) CS1h High word of a unit left eigen vector double i/o CS1 (real(8)) CS1l Low word of a unit left eigen vector double i/o CS1 (real(8)) SN1h High word of a unit right eigen vector double i/o SN1 (real(8)) SN1l Low word of a unit right eigen vector double i/o SN1 (real(8))

Routine name ddlamch Function Calculate machine parameters for floating point arithmetics Specification ddlamch(CMACH, DDLAMCHh, DDLAMCHl) Arguments Descriptions i/o Original arguments

CMACH Option for the return value character

i

DDLAMCHh High word of the return value double i/o DDLAMCHl Low word of the return value double i/o

Routine name ddlaisnan Function Return true if two values are not equal Specification ddlaisnan(DIN1h, DIN1l, DIN2h, DIN2l) Arguments

Descriptions i/o Original arguments

DIN1h High word of value for comparison double i DIN1 (real(8)) DIN1l Low word of value for comparison double i DIN1 (real(8)) DIN2h High word of value for comparison double i DIN2 (real(8)) DIN2l Low word of value for comparison double i DIN2 (real(8))

Routine name ddlamrg

Function Generate permutation lists for ascending order of integration of two sets sorted dependently

Specification ddlamrg(N1, N2, Ah, Al, STRD1, STRD2, INDEX) Arguments

Descriptions i/o Original arguments

N1 Length of the sorted list for integration integer i N2 Length of the sorted list for integration integer i

Ah High word of numbers sorted by ascending / desending fromt the first n1-th components

double i A (real(8))

Al Low word of numbers sorted by ascending / desending fromt the first n1-th components

double i A (real(8))

STRD1 Stride via an array A integer i STRD2 Stride via an array A integer i INDEX An array stored permutation integer o

Page 43: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

30

Routine name ddlanst

Function Calculate 1-norm, Frobenius norm, and infinity norm of real symmetric matrix and index of maximum absolute value of component

Specification ddlanst(NORM, N, Dh, Dl, Eh, El, DLANSTh, DLANSTl) Arguments

Descriptions i/o Original arguments

NORM Options for the return value character i N Degree of a matrix A integer i

Dh High word of an array stored diagonal components of a matrix A

double i/o D (real(8))

Dl Low word of an array stored diagonal components of a matrix A

double i/o D (real(8))

Eh High word of an array stored subdiagonal components of a matrix A

double i/o E (real(8))

El Low word of an array stored subdiagonal components of a matrix A

double i/o E (real(8))

DLANSTh High word of the return value double i DLANST (real(8)) DLANSTl Low word of the return value double i DLANST (real(8))

Routine name ddlapy2 Function Calculate SQRT(x2+y2) Specification ddlapy2(Xh, Xl, Yh, Yl, DLAPY2h, DLAPY2l) Arguments

Descriptions i/o Original arguments

Xh High word of an input value double i X (real(8)) Xl Low word of an input value double i X (real(8)) Yh High word of an input value double i Y (real(8)) Yl Low word of an input value double i Y (real(8)) DLAPY2h High word of the return value double o DLAPY2 (real(8)) DLAPY2l Low word of the return value double o DLAPY2 (real(8))

Routine name ddlascl Function Multiply a general rectangular matrix by a scalar

Specification ddlascl(TYPE, KL,KU, CFROMh, CFROMl, CTOh, CTOl, M, N, Ah, Al, LDA,INFO)

Arguments

Descriptions i/o Original arguments

TYPE Storage format of a matrix A character i KL Lower band width of a matrix A integer i KU Upper band width of a matrix A integer i CFROMh High word of a multicand CFROM double i CFROM (real(8)) CFROMl Low word of a multicand CFROM double i CFROM (real(8)) CTOh High word of a multicand CTO double i CTO (real(8)) CTOl Low word of a multicand CTO double i CTO (real(8)) M Row size of a matrix A integer i N Column size of a matrix A integer i Ah High word of the multiplicand matrix double i/o A (real(8)) Al Low word of the multiplicand matrix double i/o A (real(8)) LDA Size of a matrix A integer i INFO Information flag integer o

Page 44: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

31

Routine name ddlaset

Function Initialize off-diagonal and diagonal components of a matrix by specified values

Specification ddlaset(UPLO, M, N, ALPHAh, ALPHAl, BETAh, BETAl, Ah, Al, LDA) Arguments

Descriptions i/o Original arguments

UPLO

Option of calculation U : upper trianglular components of a matrix A L : lower triangular components of a matrix A other : all components of a matrix A

character i

M Row size of a matrix A integer i N Column size of a matrix A integer i ALPHAh 非 High word of diagonal components double i/o D (real(8)) ALPHAl 非 Low word of diagonal components double i/o D (real(8)) BETAh High word of diagonal components double i/o E (real(8)) BETAl Low word of diagonal components double i/o E (real(8)) Ah High word of the multiplicand matrix double i/o A (real(8)) Al Low word of the multiplicand matrix double i/o A (real(8)) LDA Size of array A integer i

Routine name ddlasrt Function Sort numbers by ascending or descending order Specification ddlasrt(ID, N, Dh, Dl, INFO) Arguments

Descriptions i/o Original arguments

ID Type of sorting character i Dh High word of a sorting array double i/o D (real(8)) Dl Low word of a sorting array double i/o D (real(8)) INFO Information flag integer o

The following is an subroutine of PDDBLAS called by DDEigen_s

Routine name pddgemm

Function Calculate multiplication of scalar , matrix, and matrix then add the result to multiplication of scalr and matrix

Specification pddgemm(TRANSA, TRANSB, M, N, ALPHAh, ALPHAl, Ah, Al, IA, JA, DESCA, Bh, Bl, IB, JB, DESCB, BETAh, BETAl, Ch, Cl, IC, JC, DESCC)

Arguments

Descriptions i/o Original arguments

TRANSA Options for multiplication of a matrix A

character i

TRANSB Options for multiplication of a matrix B

character i

M Row size of a matrix A integer i N Column size of a matrix A integer i ALPHAh High word of off-diagonal components double i/o ALPHA (real(8)) ALPHAl Low word of off-diagonal components double i/o ALPHA (real(8))

Page 45: Quadruple Precision Eigenvalue Calculation Library QPEigen ...ccse.jaea.go.jp/ja/download/qpeigen_k/qpeigen_k_manual_en-1.0.pdf · Quadruple Precision Eigenvalue Calculation Library

32

Ah High word of the multiplicand matrix double i/o A (real(8)) Al Low word of the multiplicand matrix double i/o A (real(8)) IA Row size of an array A integer i JA Column size of an array A integer i DESCA Size of a matrix A integer i Bh High word of the multiplicand matrix double i/o B (real(8)) Bl Low word of the multiplicand matrix double i/o B (real(8)) IB Row size of an array B integer i JB Column size of an array B integer i DESCB Size of a matrix B integer i BETAh High word of diagonal components double i/o BETA (real(8)) BETAl Low word of diagonal components double i/o BETA (real(8)) Ch High word of the multiplicand matrix double i/o C (real(8)) Cl Low word of the multiplicand matrix double i/o C (real(8)) IC Row size of an array C integer i JC Column size of an array C integer i DESCC Size of a matrix C integer i