ABSTRACT

The data set used to illustrate the use of subroutine power is taken from Example 2.1. The output generated by the power method program is presented below.

The power method

A and x(O)

k lambda and eigenvector components

k lambda and eigenvector components

Subroutine power also implements the shifted direct power method. If the input variable, shift, is nonzero, matrix A is shifted by the value of shift before the direct power method is implemented. This implements the shifted direct power method. Example 2.3 illustrating the shifted direct power method can be solved by subroutine power simply by defining norm = 2 and shift = /3.870584 in the data statement. The data statement for this additional case is included in program main as a comment statement.