Class BinaryRealTypeMath<I1 extends RealType<I1>,​I2 extends RealType<I2>,​O extends RealType<O>>


  • public class BinaryRealTypeMath<I1 extends RealType<I1>,​I2 extends RealType<I2>,​O extends RealType<O>>
    extends Object
    Binary Ops of the math namespace which operate on RealTypes. TODO: Can these be static?
    Author:
    Leon Yang, Mark Hiner
    • Field Summary

      Fields 
      Modifier and Type Field Description
      Computers.Arity2<I1,​I2,​O> adder
      Sets the real component of an output real number to the addition of the real components of two input real numbers.
      Computers.Arity2<I1,​I2,​O> ander
      Sets the real component of an output real number to the logical AND of the real component of two input real numbers.
      Computers.Arity2<I1,​I2,​O> moder
      Sets the real component of an output real number to the real component of a first input real number modulus the real component of a second input number
      Computers.Arity2<I1,​I2,​O> multiplier
      Sets the real component of an output real number to the multiplication of the real component of two input real numbers.
      Computers.Arity2<I1,​I2,​O> orer
      Sets the real component of an output real number to the logical OR of the real component of two input real numbers.
      Computers.Arity2<I1,​I2,​O> power
      Sets the real component of an output real number to the real component of a first input real number raised to the power of the real component of a second input number
      Computers.Arity2<I1,​I2,​O> subtracter
      Sets the real component of an output real number to the difference of the real component of two input real numbers.
      Computers.Arity2<I1,​I2,​O> xorer
      Sets the real component of an output real number to the logical XOR of the real component of two input real numbers.
    • Field Detail

      • adder

        public final Computers.Arity2<I1 extends RealType<I1>,​I2 extends RealType<I2>,​O extends RealType<O>> adder
        Sets the real component of an output real number to the addition of the real components of two input real numbers.
        Input parameters:
        input1
        input2
        Container parameters:
        sum
        Implementation Note:
        op names='math.add'
      • ander

        public final Computers.Arity2<I1 extends RealType<I1>,​I2 extends RealType<I2>,​O extends RealType<O>> ander
        Sets the real component of an output real number to the logical AND of the real component of two input real numbers.
        Input parameters:
        input1
        input2
        Container parameters:
        result
        Implementation Note:
        op names='math.and'
      • multiplier

        public final Computers.Arity2<I1 extends RealType<I1>,​I2 extends RealType<I2>,​O extends RealType<O>> multiplier
        Sets the real component of an output real number to the multiplication of the real component of two input real numbers.
        Input parameters:
        input1
        input2
        Container parameters:
        result
        Implementation Note:
        op names='math.mul, math.multiply'
      • orer

        public final Computers.Arity2<I1 extends RealType<I1>,​I2 extends RealType<I2>,​O extends RealType<O>> orer
        Sets the real component of an output real number to the logical OR of the real component of two input real numbers.
        Input parameters:
        input1
        input2
        Container parameters:
        result
        Implementation Note:
        op names='math.or'
      • subtracter

        public final Computers.Arity2<I1 extends RealType<I1>,​I2 extends RealType<I2>,​O extends RealType<O>> subtracter
        Sets the real component of an output real number to the difference of the real component of two input real numbers.
        Input parameters:
        input1
        input2
        Container parameters:
        result
        Implementation Note:
        op names='math.sub, math.subtract'
      • xorer

        public final Computers.Arity2<I1 extends RealType<I1>,​I2 extends RealType<I2>,​O extends RealType<O>> xorer
        Sets the real component of an output real number to the logical XOR of the real component of two input real numbers.
        Input parameters:
        input1
        input2
        Container parameters:
        result
        Implementation Note:
        op names='math.xor'
      • power

        public final Computers.Arity2<I1 extends RealType<I1>,​I2 extends RealType<I2>,​O extends RealType<O>> power
        Sets the real component of an output real number to the real component of a first input real number raised to the power of the real component of a second input number
        Input parameters:
        input1
        input2
        Container parameters:
        result
        Implementation Note:
        op names='math.pow, math.power'
      • moder

        public final Computers.Arity2<I1 extends RealType<I1>,​I2 extends RealType<I2>,​O extends RealType<O>> moder
        Sets the real component of an output real number to the real component of a first input real number modulus the real component of a second input number
        Input parameters:
        input1
        input2
        Container parameters:
        result
        Implementation Note:
        op names='math.modulus, math.mod, math.remainder'
    • Constructor Detail

      • BinaryRealTypeMath

        public BinaryRealTypeMath()
    • Method Detail

      • divider

        public static <T1 extends RealType<T1>,​T2 extends RealType<T2>,​O extends RealType<O>> void divider​(T1 input1,
                                                                                                                       T2 input2,
                                                                                                                       Double dbzVal,
                                                                                                                       O output)
        Sets the real component of an output real number to the division of the real component of two input real numbers, with optional zero-value to use in case of zero division.
        Parameters:
        input1 -
        input2 -
        dbzVal -
        output -
        Implementation Note:
        op names='math.div, math.divide', type=Computer