cern.jet.math.tint
Class IntPlusMultSecond
- java.lang.Object
-
- cern.jet.math.tint.IntPlusMultSecond
-
- All Implemented Interfaces:
- IntIntFunction
public final class IntPlusMultSecond extends java.lang.Object implements IntIntFunction
Only for performance tuning of compute intensive linear algebraic computations. Constructs functions that return one of- a + b*constant
- a - b*constant
- a + b/constant
- a - b/constant
-
-
Field Summary
Fields Modifier and Type Field and Description intmultiplicatorPublic read/write access to avoid frequent object construction.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method and Description intapply(int a, int b)Returns the result of the function evaluation.static IntPlusMultSecondminusMult(int constant)a - b*constant.static IntPlusMultSecondplusMult(int constant)a + b*constant.
-
-
-
Field Detail
-
multiplicator
public int multiplicator
Public read/write access to avoid frequent object construction.
-
-
Method Detail
-
apply
public final int apply(int a, int b)Returns the result of the function evaluation.- Specified by:
applyin interfaceIntIntFunction- Parameters:
a- the first argument passed to the function.b- the second argument passed to the function.- Returns:
- the result of the function.
-
minusMult
public static IntPlusMultSecond minusMult(int constant)
a - b*constant.
-
plusMult
public static IntPlusMultSecond plusMult(int constant)
a + b*constant.
-
-
DMelt 3.0 © DataMelt by jWork.ORG