Class BinaryNumericTypeMath<T extends NumericType<T>>


  • public class BinaryNumericTypeMath<T extends NumericType<T>>
    extends Object
    Binary Ops of the math namespace which operate on NumericTypes. TODO: Can these be static?
    Author:
    Leon Yang, Mark Hiner
    • Field Detail

      • multiplier

        public final Computers.Arity2<T extends NumericType<T>,​T extends NumericType<T>,​T extends NumericType<T>> multiplier
        Multiply two numeric types
        Input parameters:
        input1
        input2
        Container parameters:
        output
        Implementation Note:
        op names='math.mul, math.multiply', priority='100.'
      • subtracter

        public final Computers.Arity2<T extends NumericType<T>,​T extends NumericType<T>,​T extends NumericType<T>> subtracter
        Subtract a second numeric type from a first
        Input parameters:
        input1
        input2
        Container parameters:
        output
        Implementation Note:
        op names='math.sub, math.subtract', priority='100.'
      • power

        public final Computers.Arity2<T extends NumericType<T>,​T extends NumericType<T>,​T extends NumericType<T>> power
        Raise a first numeric type to the power of a second
        Input parameters:
        input1
        input2
        Container parameters:
        result
        Implementation Note:
        op names='math.pow, math.power', priority='100.'
    • Constructor Detail

      • BinaryNumericTypeMath

        public BinaryNumericTypeMath()
    • Method Detail

      • divider

        public static <N extends NumericType<N>> void divider​(N input1,
                                                              N input2,
                                                              N dbzVal,
                                                              N output)
        Divide a first numeric type by a second, with optional zero-value to use in case of zero division.
        Parameters:
        input1 -
        input2 -
        dbzVal -
        output -
        Implementation Note:
        op names='math.div, math.divide', priority='100.', type=Computer