package com.imsl.test.example.math; import com.imsl.math.*; /** *
* Computes the eigenvalues and eigenvectors of a matrix.
* * @see Code * @see Output */ public class EigenEx1 { public static void main(String args[]) throws Eigen.DidNotConvergeException { double a[][] = { {8, -1, -5}, {-4, 4, -2}, {18, -5, -7} }; Eigen eigen = new Eigen(); eigen.solve(a, true); new PrintMatrix("Eigenvalues").print(eigen.getValues()); new PrintMatrix("Eigenvectors").print(eigen.getVectors()); } }