Package functions.commutative.integer
Class LCM
- All Implemented Interfaces:
Differentiable,Evaluable,Outputable,Simplifiable,Comparable<GeneralFunction>,Iterable<GeneralFunction>
public class LCM extends IntegerCommutativeFunction
-
Field Summary
-
Constructor Summary
Constructors Constructor Description LCM(GeneralFunction... functions)Constructs a newLCM -
Method Summary
Modifier and Type Method Description GeneralFunctionclone()Returns a clone of thisGeneralFunctiondoublegetIdentityValue()Returns the identity of thisCommutativeFunction, such as 0 for + or gcd and 1 for * or lcmCommutativeFunctiongetInstance(GeneralFunction... functions)Returns an instance of thisGeneralFunctionprotected longoperateInt(int... operands)Performs the operation of this function on the inputsMethods inherited from class CommutativeFunction
compareSelf, equalsFunction, getFunctions, getJoiningCollector, hashCode, iterator, simplify, simplifyConstants, simplifyElements, simplifyIdentity, simplifyInternal, simplifyPull, simplifyTrivialElement, substituteAll, toOutputFunction, toStringMethods inherited from class GeneralFunction
compareTo, derivativeAt, equals, equalsSimplified, getNthDerivative, getSimplifiedDerivative, substituteVariables
-
Constructor Details
-
LCM
Constructs a newLCM- Parameters:
functions- theGeneralFunctions that will be acted on
-
-
Method Details
-
operateInt
protected long operateInt(int... operands)Description copied from class:IntegerCommutativeFunctionPerforms the operation of this function on the inputs- Specified by:
operateIntin classIntegerCommutativeFunction- Parameters:
operands- the list of inputs- Returns:
- the operation applied to the inputs
-
getInstance
Description copied from class:CommutativeFunctionReturns an instance of thisGeneralFunction- Specified by:
getInstancein classCommutativeFunction- Parameters:
functions- theGeneralFunctions that will be acted on- Returns:
- an instance of this
GeneralFunction
-
clone
Description copied from class:GeneralFunctionReturns a clone of thisGeneralFunction- Specified by:
clonein classGeneralFunction- Returns:
- a clone of this function
-
getIdentityValue
public double getIdentityValue()Description copied from class:CommutativeFunctionReturns the identity of thisCommutativeFunction, such as 0 for + or gcd and 1 for * or lcm- Specified by:
getIdentityValuein classCommutativeFunction- Returns:
- the identity of this
CommutativeFunction
-