applicationlayer.linearalgebra
Class AbstractMatrix

java.lang.Object
  extended by applicationlayer.linearalgebra.AbstractMatrix
Direct Known Subclasses:
CMatrix, DMatrix

public abstract class AbstractMatrix
extends java.lang.Object

Abstraktní třída prezentuje obecnou matici.


Field Summary
protected  int column
          Počet sloupců matice
static int CRAMERS_RULE
          Režim řešení soustavy rovnic - cramerovo pravidlo
static int GAUSS_ELIMINATION
          Režim řešení soustavy rovnic - Gaussova eliminace
static int GAUSS_JORDAN
          Režim řešení soustavy rovnic - Gauss-Jordanova eliminace
static int GAUSS_PARTIAL_PIVOT
          Režim řešení soustavy rovnic - Gaussova eliminace s parciální pivotací
static int INVERSION
          Režim řešení soustavy rovnic - pomocí inverzné matice
protected static int precision
          Přesnost prvků matice
protected  int row
          Počet řádků matice
 
Constructor Summary
protected AbstractMatrix()
          Vytvoří prázdnou matici.
  AbstractMatrix(int row, int column)
          Vytvoří prázdnou matici.
 
Method Summary
abstract  AbstractMatrix add(AbstractMatrix operand)
          Vrací součet dvou matic (this + operand)
abstract  java.lang.Object cond()
          Vrací číslo podmíněnosti této matice.
abstract  AbstractMatrix cramersRule(AbstractMatrix a, AbstractMatrix b)
          Řeší soustavu rovnic s cramerovým pravidem.
abstract  java.lang.Object determinant()
          Vrácí determinant této matice.
abstract  AbstractMatrix gaussElimination()
          Vrací tuto matici upravenou Gaussovou eliminací.
abstract  AbstractMatrix gaussJordan()
          Vrací tuto matici upravenou Gauss-Jordanovou eliminací.
abstract  AbstractMatrix gaussPartial()
          Vrací tuto matici upravenou Gaussovou eliminací s parciální pivotací.
 int getColumn()
          Vrací počet sloupe.
 int getRow()
          Vrací počet řádku.
abstract  AbstractMatrix inverse()
          Vrácí inverzní matici - metoda Gaussova eliminační
abstract  AbstractMatrix joinMatrix(AbstractMatrix operand)
          Vrací matici (this + operand).
abstract  AbstractMatrix multiply(AbstractMatrix operand)
          Vrací součin dvou matic (this * operand)
abstract  java.lang.Object normCol()
          Sloupcová norma.
abstract  java.lang.Object normRow()
          Řádková norma.
abstract  AbstractMatrix solve(AbstractMatrix a, AbstractMatrix b, int method)
          Řeší soustavu rovnic s danou metodou.
abstract  AbstractMatrix subtract(AbstractMatrix operand)
          Vrací rozdíl dvou matic (this - operand).
abstract  AbstractMatrix transpose()
          Vrací transpanovanou matici.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

row

protected int row
Počet řádků matice


column

protected int column
Počet sloupců matice


precision

protected static int precision
Přesnost prvků matice


INVERSION

public static final int INVERSION
Režim řešení soustavy rovnic - pomocí inverzné matice

See Also:
Constant Field Values

CRAMERS_RULE

public static final int CRAMERS_RULE
Režim řešení soustavy rovnic - cramerovo pravidlo

See Also:
Constant Field Values

GAUSS_JORDAN

public static final int GAUSS_JORDAN
Režim řešení soustavy rovnic - Gauss-Jordanova eliminace

See Also:
Constant Field Values

GAUSS_ELIMINATION

public static final int GAUSS_ELIMINATION
Režim řešení soustavy rovnic - Gaussova eliminace

See Also:
Constant Field Values

GAUSS_PARTIAL_PIVOT

public static final int GAUSS_PARTIAL_PIVOT
Režim řešení soustavy rovnic - Gaussova eliminace s parciální pivotací

See Also:
Constant Field Values
Constructor Detail

AbstractMatrix

protected AbstractMatrix()
Vytvoří prázdnou matici.


AbstractMatrix

public AbstractMatrix(int row,
                      int column)
Vytvoří prázdnou matici.

Parameters:
row -
column -
Method Detail

joinMatrix

public abstract AbstractMatrix joinMatrix(AbstractMatrix operand)
Vrací matici (this + operand).

Parameters:
operand - matice, která má být spojena k této matici
Returns:
matice s hodnoty součtu této matice s maticí v parametru ()

add

public abstract AbstractMatrix add(AbstractMatrix operand)
Vrací součet dvou matic (this + operand)

Parameters:
operand - matice, která má být přičtena k této matici
Returns:
(this + operand)

subtract

public abstract AbstractMatrix subtract(AbstractMatrix operand)
Vrací rozdíl dvou matic (this - operand).

Parameters:
operand - matice, která má být odečtena od této matici
Returns:
(this - operand)

multiply

public abstract AbstractMatrix multiply(AbstractMatrix operand)
Vrací součin dvou matic (this * operand)

Parameters:
operand - matice, která má být násobena touto maticí
Returns:
(this * operand)

cond

public abstract java.lang.Object cond()
Vrací číslo podmíněnosti této matice.

Returns:
číslo podmíněnosti

normCol

public abstract java.lang.Object normCol()
Sloupcová norma.

Returns:
maximální součet ve sloupcích

normRow

public abstract java.lang.Object normRow()
Řádková norma.

Returns:
maximální součet v řádcích

determinant

public abstract java.lang.Object determinant()
Vrácí determinant této matice.

Returns:
determinant této matice

inverse

public abstract AbstractMatrix inverse()
Vrácí inverzní matici - metoda Gaussova eliminační

Returns:
nová matice s hodnoty inverze této matice

transpose

public abstract AbstractMatrix transpose()
Vrací transpanovanou matici.

Returns:
nová matice s transpanovanými hodnotami této matice

gaussJordan

public abstract AbstractMatrix gaussJordan()
Vrací tuto matici upravenou Gauss-Jordanovou eliminací.

Returns:
diagonální tvar této matice (this)

gaussPartial

public abstract AbstractMatrix gaussPartial()
Vrací tuto matici upravenou Gaussovou eliminací s parciální pivotací.

Returns:
horní trojuhelníkový tvar(this)

gaussElimination

public abstract AbstractMatrix gaussElimination()
Vrací tuto matici upravenou Gaussovou eliminací.

Returns:
horní trojuhelnikový tvar (this)

cramersRule

public abstract AbstractMatrix cramersRule(AbstractMatrix a,
                                           AbstractMatrix b)
Řeší soustavu rovnic s cramerovým pravidem.

Parameters:
a - matice soustavy
b - pravá strana soustavy
Returns:
výsledek soustavy

solve

public abstract AbstractMatrix solve(AbstractMatrix a,
                                     AbstractMatrix b,
                                     int method)
Řeší soustavu rovnic s danou metodou.

Parameters:
a - matice soustavy
b - pravá strana soustavy
method - metoda, která má být použita při výpočtu řešení soustavy rovnic.
Returns:
výsledek soustavy

getRow

public int getRow()
Vrací počet řádku.

Returns:
the row

getColumn

public int getColumn()
Vrací počet sloupe.

Returns:
the column