Package org.nlpub.watset.util
Class Matrices.InflateVisitor
java.lang.Object
org.apache.commons.math3.linear.DefaultRealMatrixChangingVisitor
org.nlpub.watset.util.Matrices.InflateVisitor
- All Implemented Interfaces:
org.apache.commons.math3.linear.RealMatrixChangingVisitor
- Enclosing class:
- Matrices
public static class Matrices.InflateVisitor
extends org.apache.commons.math3.linear.DefaultRealMatrixChangingVisitor
Visitor that raises each element to the specified power.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondoublevisit(int row, int column, double value) Raise the value of a single element to the power ofr.Methods inherited from class org.apache.commons.math3.linear.DefaultRealMatrixChangingVisitor
end, start
-
Constructor Details
-
InflateVisitor
public InflateVisitor(double r) Create an instance of the inflator.- Parameters:
r- the inflation parameter
-
-
Method Details
-
visit
public double visit(int row, int column, double value) Raise the value of a single element to the power ofr.- Specified by:
visitin interfaceorg.apache.commons.math3.linear.RealMatrixChangingVisitor- Overrides:
visitin classorg.apache.commons.math3.linear.DefaultRealMatrixChangingVisitor- Parameters:
row- rowcolumn- columnvalue- the value- Returns:
- the value raised to the power of
r
-