/* ## class FPacked ## ## This class holds the framework for a matrix stored in packed form. ## It contains all the necessary basic routines for matrices adjusted ## for its form. ## */ package edu.rice.linpack.Matrix.FMatrix; import edu.rice.linpack.LNumber.*; import edu.rice.linpack.Vector.*; import edu.rice.linpack.util.*; public abstract class FPacked extends FMatrix { protected int order; public abstract void factor() throws SingularMatrixException; public abstract LNumber condition() throws SingularMatrixException, WrongDataTypeException; public abstract LNumber condition(Vector Z) throws SingularMatrixException, WrongDataTypeException; public abstract void solve(Vector B, int J) throws WrongDataTypeException; public abstract void solve(Vector B) throws WrongDataTypeException; public abstract Vector determ(); public abstract void inverse(); public float getElem(int i) { return Mat[i][0]; } public float[] getColumn(int q) { return getColumn(0,q); } public int getOrder() { return order; } public static float[][] pack(float[][] f) { int k = 0; int n = f.length; float[][] R = new float[(n*(n+1))/2][1]; for(int j=0;j