Package org.ojalgo.function
Interface BinaryFunction<N extends Comparable<N>>
- All Superinterfaces:
BasicFunction
,BiFunction<N,
,N, N> BinaryOperator<N>
,DoubleBinaryOperator
- All Known Subinterfaces:
BigFunction.Binary
,ComplexFunction.Binary
,PrimitiveFunction.Binary
,QuadrupleFunction.Binary
,QuaternionFunction.Binary
,RationalFunction.Binary
- All Known Implementing Classes:
ArtificialNeuralNetwork.Error
public interface BinaryFunction<N extends Comparable<N>>
extends BasicFunction, BinaryOperator<N>, DoubleBinaryOperator
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final class
BinaryFunction.FixedFirst<N extends Comparable<N>>
A BinaryFunction with a set/fixed first argument.static final class
BinaryFunction.FixedSecond<N extends Comparable<N>>
A BinaryFunction with a set/fixed second argument.Nested classes/interfaces inherited from interface org.ojalgo.function.BasicFunction
BasicFunction.Differentiable<N extends Comparable<N>,
F extends BasicFunction>, BasicFunction.Integratable<N extends Comparable<N>, F extends BasicFunction>, BasicFunction.PlainUnary<T, R> -
Method Summary
Modifier and TypeMethodDescriptiondefault BinaryFunction
<N> andThen
(UnaryFunction<N> after) default N
default double
applyAsDouble
(double arg1, double arg2) default UnaryFunction
<N> by
(double arg2) To allow syntax likearray.modifyAll(DIVIDE.by(3.0));
default UnaryFunction
<N> To allow syntax likearray.modifyAll(DIVIDE.by(3.0));
default UnaryFunction
<N> first
(double arg1) default UnaryFunction
<N> Turns this binary function into a unary function with the first argument fixed/locked to the specified value.default byte
invoke
(byte arg1, byte arg2) double
invoke
(double arg1, double arg2) default float
invoke
(float arg1, float arg2) default int
invoke
(int arg1, int arg2) default long
invoke
(long arg1, long arg2) default short
invoke
(short arg1, short arg2) default UnaryFunction
<N> second
(double arg2) default UnaryFunction
<N> Turns this binary function into a unary function with the second argument fixed/locked to the specified value.Methods inherited from interface java.util.function.BiFunction
andThen
-
Method Details
-
andThen
-
apply
- Specified by:
apply
in interfaceBiFunction<N extends Comparable<N>,
N extends Comparable<N>, N extends Comparable<N>> - See Also:
-
applyAsDouble
default double applyAsDouble(double arg1, double arg2) - Specified by:
applyAsDouble
in interfaceDoubleBinaryOperator
- See Also:
-
by
To allow syntax likearray.modifyAll(DIVIDE.by(3.0));
- See Also:
-
by
To allow syntax likearray.modifyAll(DIVIDE.by(3.0));
- See Also:
-
first
- See Also:
-
first
Turns this binary function into a unary function with the first argument fixed/locked to the specified value.- Parameters:
arg1
- The first argument of the binary function.- Returns:
- The resulting unary function.
-
invoke
default byte invoke(byte arg1, byte arg2) -
invoke
double invoke(double arg1, double arg2) -
invoke
default float invoke(float arg1, float arg2) -
invoke
default int invoke(int arg1, int arg2) -
invoke
default long invoke(long arg1, long arg2) -
invoke
-
invoke
-
invoke
default short invoke(short arg1, short arg2) -
second
- See Also:
-
second
Turns this binary function into a unary function with the second argument fixed/locked to the specified value.- Parameters:
arg2
- The second argument of the binary function.- Returns:
- The resulting unary function.
-