org.mklab.nfc.matrix
クラス RationalPolynomialMatrix

java.lang.Object
  上位を拡張 org.mklab.nfc.matrix.AbstractGrid<M>
      上位を拡張 org.mklab.nfc.matrix.AbstractFundamentalMatrix<M>
          上位を拡張 org.mklab.nfc.matrix.AbstractMatrix<M>
              上位を拡張 org.mklab.nfc.matrix.BaseMatrix<M,E>
                  上位を拡張 org.mklab.nfc.matrix.SymbolicMatrix<RationalPolynomialMatrix,RationalPolynomial>
                      上位を拡張 org.mklab.nfc.matrix.RationalPolynomialMatrix
すべての実装されたインタフェース:
Serializable, Cloneable, FundamentalMatrix, Grid, Matrix, MatrixElementOperator<RationalPolynomial>, MatrixElementWiseOperator, SymbolicMatrixOperator<RationalPolynomial>, TransformableMatrix<BaseMatrix<?,?>>, MatxObject
直系の既知のサブクラス:
MatxRationalPolynomialArray

public class RationalPolynomialMatrix
extends SymbolicMatrix<RationalPolynomialMatrix,RationalPolynomial>
implements MatxObject

有理多項式(RationalPolynomial)を成分とする行列を表すクラスです。

バージョン:
$Revision: 1.139 $
作成者:
Koga Laboratory
関連項目:
直列化された形式

コンストラクタの概要
RationalPolynomialMatrix()
          新しく生成されたRationalPolynomialMatrixオブジェクトを初期化します。
RationalPolynomialMatrix(DoubleMatrix matrix)
          新しく生成されたRationalPolynomialMatrixオブジェクトを初期化します。
RationalPolynomialMatrix(int rowSize, int columnSize)
          新しく生成されたRationalPolynomialMatrixオブジェクトを初期化します。
RationalPolynomialMatrix(int rowSize, int columnSize, Scalar<?>[][] elements)
          新しく生成されたRationalPolynomialMatrixオブジェクトを初期化します。
RationalPolynomialMatrix(int rowSize, int columnSize, String variableName)
          新しく生成されたRationalPolynomialMatrixオブジェクトを初期化します。
RationalPolynomialMatrix(IntMatrix matrix)
          新しく生成されたRationalPolynomialMatrixオブジェクトを初期化します。
RationalPolynomialMatrix(NumericalMatrix<?> matrix)
          新しく生成されたRationalPolynomialMatrixオブジェクトを初期化します。
RationalPolynomialMatrix(PolynomialMatrix matrix)
          新しく生成されたRationalPolynomialMatrixオブジェクトを初期化します。
RationalPolynomialMatrix(Scalar<?>[] elements)
          新しく生成されたRationalPolynomialMatrixオブジェクトを初期化します。
RationalPolynomialMatrix(Scalar<?>[][] elements)
          新しく生成されたRationalPolynomialMatrixオブジェクトを初期化します。
 
メソッドの概要
static RationalPolynomialMatrix diagonal(RationalPolynomial[] diagonalElement)
          対角行列を生成します。
 PolynomialMatrix getDenominatorElementWise()
          成分毎の分母多項式を成分とする行列を返します。
protected  String getGridClassName()
          出力するクラスの名前を返します。
 PolynomialMatrix getNumeratorElementWise()
          成分毎の分子多項式を成分とする行列を返します。
 PolynomialMatrix getQuotientElementWise()
          成分毎の商多項式を成分とする行列を返します。
 PolynomialMatrix getRemainderElementWise()
          成分毎の剰余多項式を成分とする行列を返します。
 int hashCode()
          Override hashCode.
 boolean isTransformableFrom(Matrix value)
          引数で与えられた型から、この型へ変換可能か判定します。
static RationalPolynomialMatrix ones(int size)
          全ての成分が1である正方行列を生成します。
static RationalPolynomialMatrix ones(int rowSize, int columnSize)
          全ての成分が1である行列を生成します。
static RationalPolynomialMatrix ones(int rowSize, int columnSize, String variableName)
          全ての成分が1である行列を生成します。
static RationalPolynomialMatrix ones(int size, String variableName)
          全ての成分が1である正方行列を生成します。
static RationalPolynomialMatrix powerElementWise(RationalPolynomial scalar, IntMatrix matrix)
          1個の有理多項式について、行列の各成分の累乗を求めます。
static RationalPolynomialMatrix powerElementWise(RationalPolynomial scalar, Matrix matrix)
          1個の有理多項式について、行列の各成分の累乗を求めます。
 void printElements(Writer output)
          ライターに成分を出力します。
 void printElements(Writer output, int maxColumnSize)
          ライターに成分を出力します。
static RationalPolynomialMatrix readMxFormat(InputStream input, MxDataHead head)
          入力ストリームからMX形式のデータを読み込みます。
 String toMmString()
          MM形式の文字列を生成します。
 String toMmString(String format)
          MM形式の文字列を生成します。
 Matrix transformFrom(Matrix value)
          引数で与えられた型からこの型へ変換します。
static RationalPolynomialMatrix unit(int size)
          単位行列を生成します。
static RationalPolynomialMatrix unit(int rowSize, int columnSize)
          単位行列を生成します。
static RationalPolynomialMatrix unit(int rowSize, int columnSize, String variableName)
          単位行列を生成します。
static RationalPolynomialMatrix unit(int size, String variableName)
          単位行列を生成します。
 void writeMmFormat(String fileName, String name)
          MMファイル形式で行列データをファイルに出力します。
 void writeMmFormat(Writer output, String name, boolean withNewLine)
          MMフォーマット行列データをライターに出力します。
 void writeMxFormat(OutputStream output, String name)
          データをMX形式で出力ストリームへ出力します。
 void writeMxFormat(String fileName, String name)
          データをMX形式でファイルへ出力します。
 
クラス org.mklab.nfc.matrix.SymbolicMatrix から継承されたメソッド
derivative, derivative, evaluate, evaluate, evaluate, evaluate, evaluate, evaluateElementWise, setVariable, shiftHigher, shiftHigher, shiftLower, shiftLower
 
クラス org.mklab.nfc.matrix.BaseMatrix から継承されたメソッド
add, add, addElementWise, addElementWise, addElementWise, appendDown, appendDown, appendRight, appendRight, ceilElementWise, clone, compareElementWise, compareElementWise, compareElementWise, compareElementWise, compareElementWise, compareElementWise, compareElementWise, conjugate, conjugateTranspose, copy, copy, copy, copy, covariance, covariance, createOnes, createUnit, createZero, cumulativeProduct, cumulativeProductColumnWise, cumulativeProductRowWise, cumulativeSum, cumulativeSumColumnWise, cumulativeSumRowWise, determinant, diagonal, diagonalToVector, divide, divide, divide, divide, divide, divideElementWise, divideElementWise, equals, equals, equals, exchangeColumn, exchangeRow, fixElementWise, floorElementWise, getElement, getElement, getElements, getImaginaryPart, getRealPart, getSubMatrix, getSubMatrix, getSubMatrix, getSubMatrix, getSubVector, inverse, inverse, inverseElementWise, isComplex, isFiniteElementWise, isInfiniteElementWise, isNanElementWise, isReal, isTransformableTo, isUnit, isZero, isZero, leftDivide, leftDivide, leftDivideElementWise, leftDivideElementWise, mean, meanColumnWise, meanRowWise, multiply, multiply, multiply, multiply, multiply, multiplyElementWise, multiplyElementWise, powerElementWise, powerElementWise, product, productColumnWise, productRowWise, removeColumnVectors, removeColumnVectors, removeRowVectors, removeRowVectors, reshape, resize, roundElementWise, roundToZeroElementWise, setElement, setElement, setElement, setElement, setElement, setElement, setElements, setImaginaryPart, setImaginaryPart, setImaginaryPart, setImaginaryPart, setRealPart, setRealPart, setRealPart, setRealPart, setSubMatrix, setSubMatrix, setSubMatrix, setSubMatrix, setSubVector, setSubVector, subtract, subtract, subtractElementWise, subtractElementWise, subtractElementWise, sum, sumColumnWise, sumRowWise, toComplex, trace, transformTo, transpose, unaryMinus, variance, vectorToDiagonal
 
クラス org.mklab.nfc.matrix.AbstractMatrix から継承されたメソッド
add, covariance, createOnes, createOnes, createOnes, createUnit, createUnit, createUnit, createZero, createZero, createZero, divide, divideElementWise, isUnit, leftDivide, leftDivide, leftDivide, leftDivide, leftDivideElementWise, multiply, multiplyElementWise, power, powerElementWise, roundToZeroElementWise, shiftLeft, shiftUp, subtract, transformToSameClass
 
クラス org.mklab.nfc.matrix.AbstractFundamentalMatrix から継承されたメソッド
appendDown, appendRight, flipLeftRight, flipUpDown, getColumnVector, getColumnVectors, getColumnVectors, getRowVector, getRowVectors, getRowVectors, getSubMatrix, getSubMatrix, getSubMatrix, getSubVector, getSubVector, rotateLeft, rotateUp, setColumnVector, setColumnVectors, setColumnVectors, setRowVector, setRowVectors, setRowVectors, setSubMatrix, setSubMatrix, setSubMatrix, setSubVector
 
クラス org.mklab.nfc.matrix.AbstractGrid から継承されたメソッド
count, getColumnSize, getDefaultElementAlignment, getDefaultElementFormat, getElementAlignment, getElementFormat, getPrintingElementsString, getPrintingString, getRowSize, hasSameColumnSize, hasSameRowSize, isEmpty, isSameSize, isSquare, length, print, print, print, removeColumnVector, removeRowVector, setColumnSize, setDefaultElementAlignment, setDefaultElementFormat, setElementAlignment, setElementFormat, setRowSize, toString
 
クラス java.lang.Object から継承されたメソッド
finalize, getClass, notify, notifyAll, wait, wait, wait
 
インタフェース org.mklab.nfc.matrix.Matrix から継承されたメソッド
add, conjugate, conjugateTranspose, covariance, createOnes, createOnes, createOnes, createOnes, createUnit, createUnit, createUnit, createUnit, createZero, createZero, createZero, createZero, cumulativeProduct, cumulativeProductColumnWise, cumulativeProductRowWise, cumulativeSum, cumulativeSumColumnWise, cumulativeSumRowWise, divide, divide, divide, divide, getImaginaryPart, getRealPart, inverse, inverse, isComplex, isReal, isTransformableTo, isUnit, isUnit, isZero, leftDivide, leftDivide, leftDivide, leftDivide, meanColumnWise, meanRowWise, multiply, multiply, multiply, multiply, power, productColumnWise, productRowWise, setImaginaryPart, setImaginaryPart, setImaginaryPart, setImaginaryPart, setRealPart, setRealPart, setRealPart, setRealPart, shiftLeft, shiftUp, subtract, sumColumnWise, sumRowWise, toComplex, transformTo, unaryMinus
 
インタフェース org.mklab.nfc.matrix.FundamentalMatrix から継承されたメソッド
appendDown, appendRight, compareElementWise, copy, diagonalToVector, equals, flipLeftRight, flipUpDown, getColumnVector, getColumnVectors, getColumnVectors, getRowVector, getRowVectors, getRowVectors, getSubMatrix, getSubMatrix, getSubMatrix, getSubMatrix, getSubMatrix, getSubMatrix, getSubMatrix, getSubVector, getSubVector, getSubVector, reshape, resize, rotateLeft, rotateUp, setColumnVector, setColumnVectors, setColumnVectors, setRowVector, setRowVectors, setRowVectors, setSubMatrix, setSubMatrix, setSubMatrix, setSubMatrix, setSubMatrix, setSubMatrix, setSubMatrix, setSubVector, setSubVector, setSubVector, transpose, vectorToDiagonal
 
インタフェース org.mklab.nfc.matrix.Grid から継承されたメソッド
clone, count, exchangeColumn, exchangeRow, getColumnSize, getElementAlignment, getElementFormat, getPrintingElementsString, getPrintingString, getRowSize, hasSameColumnSize, hasSameRowSize, isEmpty, isSameSize, isSquare, isZero, length, print, print, print, removeColumnVector, removeColumnVectors, removeColumnVectors, removeRowVector, removeRowVectors, removeRowVectors, setElementAlignment, setElementFormat
 
インタフェース org.mklab.nfc.matrix.MatrixElementWiseOperator から継承されたメソッド
addElementWise, addElementWise, addElementWise, ceilElementWise, compareElementWise, compareElementWise, compareElementWise, divideElementWise, fixElementWise, floorElementWise, inverseElementWise, isFiniteElementWise, isInfiniteElementWise, isNanElementWise, leftDivideElementWise, multiplyElementWise, powerElementWise, powerElementWise, powerElementWise, roundElementWise, roundToZeroElementWise, roundToZeroElementWise, subtractElementWise, subtractElementWise, subtractElementWise
 
インタフェース org.mklab.nfc.matrix.MatrixElementOperator から継承されたメソッド
copy, copy, determinant, getElement, getElement, mean, product, setElement, setElement, setElement, setElement, setElement, setElement, sum, trace, variance
 

コンストラクタの詳細

RationalPolynomialMatrix

public RationalPolynomialMatrix()
新しく生成されたRationalPolynomialMatrixオブジェクトを初期化します。


RationalPolynomialMatrix

public RationalPolynomialMatrix(Scalar<?>[] elements)
新しく生成されたRationalPolynomialMatrixオブジェクトを初期化します。

パラメータ:
elements - ベクトルの成分をもつ配列

RationalPolynomialMatrix

public RationalPolynomialMatrix(int rowSize,
                                int columnSize)
新しく生成されたRationalPolynomialMatrixオブジェクトを初期化します。

パラメータ:
rowSize - 行の数
columnSize - 列の数

RationalPolynomialMatrix

public RationalPolynomialMatrix(int rowSize,
                                int columnSize,
                                String variableName)
新しく生成されたRationalPolynomialMatrixオブジェクトを初期化します。

パラメータ:
rowSize - 行の数
columnSize - 列の数
variableName - 変数名

RationalPolynomialMatrix

public RationalPolynomialMatrix(Scalar<?>[][] elements)
新しく生成されたRationalPolynomialMatrixオブジェクトを初期化します。

パラメータ:
elements - 行列の成分をもつ配列

RationalPolynomialMatrix

public RationalPolynomialMatrix(int rowSize,
                                int columnSize,
                                Scalar<?>[][] elements)
新しく生成されたRationalPolynomialMatrixオブジェクトを初期化します。

パラメータ:
rowSize - 行の数
columnSize - 列の数
elements - 行列の成分を持つ配列

RationalPolynomialMatrix

public RationalPolynomialMatrix(IntMatrix matrix)
新しく生成されたRationalPolynomialMatrixオブジェクトを初期化します。

パラメータ:
matrix - 整数行列

RationalPolynomialMatrix

public RationalPolynomialMatrix(DoubleMatrix matrix)
新しく生成されたRationalPolynomialMatrixオブジェクトを初期化します。

パラメータ:
matrix - 実数行列

RationalPolynomialMatrix

public RationalPolynomialMatrix(NumericalMatrix<?> matrix)
新しく生成されたRationalPolynomialMatrixオブジェクトを初期化します。

パラメータ:
matrix - 複素行列

RationalPolynomialMatrix

public RationalPolynomialMatrix(PolynomialMatrix matrix)
新しく生成されたRationalPolynomialMatrixオブジェクトを初期化します。

パラメータ:
matrix - 多項式行列
メソッドの詳細

hashCode

public int hashCode()
クラス BaseMatrix の記述:
Override hashCode.

オーバーライド:
クラス BaseMatrix<RationalPolynomialMatrix,RationalPolynomial> 内の hashCode
戻り値:
the Objects hashcode.
関連項目:
BaseMatrix.hashCode()

isTransformableFrom

public boolean isTransformableFrom(Matrix value)
インタフェース Matrix の記述:
引数で与えられた型から、この型へ変換可能か判定します。

定義:
インタフェース Matrix 内の isTransformableFrom
オーバーライド:
クラス BaseMatrix<RationalPolynomialMatrix,RationalPolynomial> 内の isTransformableFrom
パラメータ:
value - 変換元
戻り値:
変換可能ならtrue、そうでなければfalse
関連項目:
Matrix.isTransformableFrom(org.mklab.nfc.matrix.Matrix)

transformFrom

public Matrix transformFrom(Matrix value)
インタフェース Matrix の記述:
引数で与えられた型からこの型へ変換します。

定義:
インタフェース Matrix 内の transformFrom
オーバーライド:
クラス BaseMatrix<RationalPolynomialMatrix,RationalPolynomial> 内の transformFrom
パラメータ:
value - 変換元
戻り値:
変換で生成された値
関連項目:
Matrix.transformFrom(org.mklab.nfc.matrix.Matrix)

unit

public static RationalPolynomialMatrix unit(int size)
単位行列を生成します。

パラメータ:
size - 行列の大きさ
戻り値:
単位行列

unit

public static RationalPolynomialMatrix unit(int size,
                                            String variableName)
単位行列を生成します。

パラメータ:
size - 行列の大きさ
variableName - 変数名
戻り値:
単位行列

unit

public static RationalPolynomialMatrix unit(int rowSize,
                                            int columnSize)
単位行列を生成します。

パラメータ:
rowSize - 行の数
columnSize - 列の数
戻り値:
単位行列

unit

public static RationalPolynomialMatrix unit(int rowSize,
                                            int columnSize,
                                            String variableName)
単位行列を生成します。

パラメータ:
rowSize - 行の数
columnSize - 列の数
variableName - 変数名
戻り値:
単位行列

ones

public static RationalPolynomialMatrix ones(int size)
全ての成分が1である正方行列を生成します。

パラメータ:
size - 行列の大きさ
戻り値:
全ての成分が1である正方行列

ones

public static RationalPolynomialMatrix ones(int size,
                                            String variableName)
全ての成分が1である正方行列を生成します。

パラメータ:
size - 行列の大きさ
variableName - 変数名
戻り値:
全ての成分が1である正方行列

ones

public static RationalPolynomialMatrix ones(int rowSize,
                                            int columnSize)
全ての成分が1である行列を生成します。

パラメータ:
rowSize - 行の数
columnSize - 列の数
戻り値:
全ての成分が1である行列

ones

public static RationalPolynomialMatrix ones(int rowSize,
                                            int columnSize,
                                            String variableName)
全ての成分が1である行列を生成します。

パラメータ:
rowSize - 行の数
columnSize - 列の数
variableName - 変数名
戻り値:
全ての成分が1である行列

diagonal

public static RationalPolynomialMatrix diagonal(RationalPolynomial[] diagonalElement)
対角行列を生成します。

パラメータ:
diagonalElement - 対角成分
戻り値:
対角行列

getNumeratorElementWise

public PolynomialMatrix getNumeratorElementWise()
成分毎の分子多項式を成分とする行列を返します。

戻り値:
成分毎の分子多項式を成分とする行列

getDenominatorElementWise

public PolynomialMatrix getDenominatorElementWise()
成分毎の分母多項式を成分とする行列を返します。

戻り値:
成分毎の分母多項式を成分とする行列

getQuotientElementWise

public PolynomialMatrix getQuotientElementWise()
成分毎の商多項式を成分とする行列を返します。

戻り値:
成分毎の商多項式を成分とする行列

getRemainderElementWise

public PolynomialMatrix getRemainderElementWise()
成分毎の剰余多項式を成分とする行列を返します。

戻り値:
成分毎の剰余多項式を成分とする行列

writeMxFormat

public void writeMxFormat(OutputStream output,
                          String name)
                   throws IOException
インタフェース MatxObject の記述:
データをMX形式で出力ストリームへ出力します。 outputがcloseされるまで、いくつでも出力可能です。

定義:
インタフェース MatxObject 内の writeMxFormat
パラメータ:
output - 出力ストリーム
name - データの名前
例外:
IOException - 出力ストリームに出力できない場合
関連項目:
MatxObject.writeMxFormat(java.io.OutputStream, java.lang.String)

writeMxFormat

public void writeMxFormat(String fileName,
                          String name)
                   throws IOException
インタフェース MatxObject の記述:
データをMX形式でファイルへ出力します。

定義:
インタフェース MatxObject 内の writeMxFormat
パラメータ:
fileName - ファイル名
name - データの名前
例外:
IOException - ファイルに出力できない場合
関連項目:
MatxObject.writeMxFormat(java.lang.String, java.lang.String)

readMxFormat

public static RationalPolynomialMatrix readMxFormat(InputStream input,
                                                    MxDataHead head)
                                             throws IOException
入力ストリームからMX形式のデータを読み込みます。

パラメータ:
input - 入力ストリーム
head - ヘッダー
戻り値:
読み込んだデータ
例外:
IOException - 入力ストリームから読み込みない場合

toMmString

public String toMmString()
インタフェース MatxObject の記述:
MM形式の文字列を生成します。

定義:
インタフェース MatxObject 内の toMmString
戻り値:
MM形式の文字列
関連項目:
MatxObject.toMmString()

toMmString

public String toMmString(String format)
インタフェース MatxObject の記述:
MM形式の文字列を生成します。

定義:
インタフェース MatxObject 内の toMmString
パラメータ:
format - 出力フォーマット
戻り値:
MM形式の文字列
関連項目:
MatxObject.toMmString(java.lang.String)

writeMmFormat

public void writeMmFormat(String fileName,
                          String name)
                   throws IOException
インタフェース MatxObject の記述:
MMファイル形式で行列データをファイルに出力します。

定義:
インタフェース MatxObject 内の writeMmFormat
パラメータ:
fileName - ファイル名
name - 名前
例外:
IOException - ファイルに出力できない場合
関連項目:
MatxObject.writeMmFormat(java.lang.String, java.lang.String)

writeMmFormat

public void writeMmFormat(Writer output,
                          String name,
                          boolean withNewLine)
                   throws IOException
インタフェース MatxObject の記述:
MMフォーマット行列データをライターに出力します。

定義:
インタフェース MatxObject 内の writeMmFormat
パラメータ:
output - ライター
name - 名前
withNewLine - セミコロンと改行コードを出力するならばtrue、そうでなければfalse
例外:
IOException - ライターに出力できない場合
関連項目:
MatxObject.writeMmFormat(java.io.Writer, java.lang.String, boolean)

getGridClassName

protected String getGridClassName()
クラス AbstractGrid の記述:
出力するクラスの名前を返します。

オーバーライド:
クラス AbstractGrid<RationalPolynomialMatrix> 内の getGridClassName
戻り値:
出力するクラスの名前
関連項目:
AbstractGrid.getGridClassName()

printElements

public void printElements(Writer output)
インタフェース Grid の記述:
ライターに成分を出力します。

定義:
インタフェース Grid 内の printElements
オーバーライド:
クラス BaseMatrix<RationalPolynomialMatrix,RationalPolynomial> 内の printElements
パラメータ:
output - ライター
関連項目:
Grid.printElements(java.io.Writer)

printElements

public void printElements(Writer output,
                          int maxColumnSize)
インタフェース Grid の記述:
ライターに成分を出力します。

定義:
インタフェース Grid 内の printElements
オーバーライド:
クラス BaseMatrix<RationalPolynomialMatrix,RationalPolynomial> 内の printElements
パラメータ:
output - ライター
maxColumnSize - 1行の出力する列の最大数
関連項目:
Grid.printElements(java.io.Writer, int)

powerElementWise

public static RationalPolynomialMatrix powerElementWise(RationalPolynomial scalar,
                                                        Matrix matrix)
1個の有理多項式について、行列の各成分の累乗を求めます。

パラメータ:
scalar - 累乗の対象
matrix - 累乗の指数を成分とする行列
戻り値:
累乗の結果

powerElementWise

public static RationalPolynomialMatrix powerElementWise(RationalPolynomial scalar,
                                                        IntMatrix matrix)
1個の有理多項式について、行列の各成分の累乗を求めます。

パラメータ:
scalar - 累乗の対象
matrix - 累乗の指数を成分とする行列
戻り値:
累乗の結果