gausselim.pivoting
Class ScaledRowPivoting

java.lang.Object
  extended by gausselim.pivoting.ScaledRowPivoting
All Implemented Interfaces:
PivotingMethod

public class ScaledRowPivoting
extends java.lang.Object
implements PivotingMethod

Scaled row pivoting (also called implicit pivoting).


Constructor Summary
ScaledRowPivoting()
           
 
Method Summary
 int[] pivot(java.math.BigDecimal[][] a, java.math.BigDecimal[] b, int step, java.math.MathContext mc)
          Perform scaled row pivoting.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ScaledRowPivoting

public ScaledRowPivoting()
Method Detail

pivot

public int[] pivot(java.math.BigDecimal[][] a,
                   java.math.BigDecimal[] b,
                   int step,
                   java.math.MathContext mc)
Perform scaled row pivoting. At step k, this method selects the first row i so that i >= k and |A(i,k)|/M(i) >= |A(j,k)|/M(j) for any other j >= k, where M(i) is the largest absolute value in row i. Rows i and k are then swapped.

Specified by:
pivot in interface PivotingMethod
Returns:
index (row, column) of the selected pivot element.