Interface FieldDerivative<S extends CalculusFieldElement<S>,T extends FieldDerivative<S,T>>
-
- Type Parameters:
S- the type of the field elementsT- the type of the function derivative
- All Superinterfaces:
CalculusFieldElement<T>,DifferentialAlgebra,FieldElement<T>
- All Known Subinterfaces:
FieldDerivative1<S,T>
- All Known Implementing Classes:
FieldDerivativeStructure,FieldGradient,FieldUnivariateDerivative,FieldUnivariateDerivative1,FieldUnivariateDerivative2
public interface FieldDerivative<S extends CalculusFieldElement<S>,T extends FieldDerivative<S,T>> extends CalculusFieldElement<T>, DifferentialAlgebra
Interface representing both the value and the differentials of a function.- Since:
- 1.7
- See Also:
Derivative
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default Tacos()Arc cosine operation.default Tadd(S a)'+' operator.default Tceil()Get the smallest whole number larger than instance.default Tcosh()Hyperbolic cosine operation.default Tfloor()Get the largest whole number smaller than instance.default intgetExponent()Return the exponent of the instance, removing the bias.SgetPartialDerivative(int... orders)Get a partial derivative.default doublegetReal()Get the real value of the number.SgetValue()Get the value part of the function.default Tlog10()Base 10 logarithm.default TnewInstance(S value)Create an instance corresponding to a constant Field value.default Tpow(T e)Power operation.default Trint()Get the whole number that is the nearest to the instance, or the even one if x is exactly half way between two integers.default Tsign()Compute the sign of the instance.default Tsinh()Hyperbolic sine operation.default Tsubtract(S a)'-' operator.default Tulp()Compute least significant bit (Unit in Last Position) for a number.default TwithValue(S value)Create a new object with new value (zeroth-order derivative, as passed as input) and same derivatives of order one and above.-
Methods inherited from interface org.hipparchus.CalculusFieldElement
abs, acosh, add, asin, asinh, atan, atan2, atanh, cbrt, copySign, copySign, cos, divide, divide, exp, expm1, getAddendum, getPi, hypot, isFinite, isInfinite, isNaN, linearCombination, linearCombination, linearCombination, linearCombination, linearCombination, linearCombination, linearCombination, linearCombination, log, log1p, multiply, multiply, newInstance, norm, pow, pow, remainder, remainder, rootN, round, scalb, sin, sinCos, sinhCosh, sqrt, square, subtract, subtract, tan, tanh, toDegrees, toRadians
-
Methods inherited from interface org.hipparchus.analysis.differentiation.DifferentialAlgebra
getFreeParameters, getOrder
-
Methods inherited from interface org.hipparchus.FieldElement
add, getField, isZero, multiply, negate, reciprocal
-
-
-
-
Method Detail
-
getValue
S getValue()
Get the value part of the function.- Returns:
- value part of the value of the function
-
getPartialDerivative
S getPartialDerivative(int... orders) throws MathIllegalArgumentException
Get a partial derivative.- Parameters:
orders- derivation orders with respect to each variable (if all orders are 0, the value is returned)- Returns:
- partial derivative
- Throws:
MathIllegalArgumentException- if the numbers of variables does not match the instanceMathIllegalArgumentException- if sum of derivation orders is larger than the instance limits- See Also:
getValue()
-
getReal
default double getReal()
Get the real value of the number.- Specified by:
getRealin interfaceFieldElement<S extends CalculusFieldElement<S>>- Returns:
- real value
-
newInstance
default T newInstance(S value)
Create an instance corresponding to a constant Field value.This default implementation is there so that no API gets broken by the next release, which is not a major one. Custom inheritors should probably overwrite it.
- Parameters:
value- constant value- Returns:
- instance corresponding to a constant Field value
- Since:
- 3.1
-
withValue
default T withValue(S value)
Create a new object with new value (zeroth-order derivative, as passed as input) and same derivatives of order one and above.This default implementation is there so that no API gets broken by the next release, which is not a major one. Custom inheritors should probably overwrite it.
- Parameters:
value- zeroth-order derivative of new represented function- Returns:
- new object with changed value
- Since:
- 3.1
-
add
default T add(S a)
'+' operator.- Parameters:
a- right hand side parameter of the operator- Returns:
- this+a
- Since:
- 3.1
-
subtract
default T subtract(S a)
'-' operator.- Parameters:
a- right hand side parameter of the operator- Returns:
- this-a
- Since:
- 3.1
-
log10
default T log10()
Base 10 logarithm.- Specified by:
log10in interfaceCalculusFieldElement<S extends CalculusFieldElement<S>>- Returns:
- base 10 logarithm of the instance
-
pow
default T pow(T e)
Power operation.- Specified by:
powin interfaceCalculusFieldElement<S extends CalculusFieldElement<S>>- Parameters:
e- exponent- Returns:
- thise
-
cosh
default T cosh()
Hyperbolic cosine operation.- Specified by:
coshin interfaceCalculusFieldElement<S extends CalculusFieldElement<S>>- Returns:
- cosh(this)
-
sinh
default T sinh()
Hyperbolic sine operation.- Specified by:
sinhin interfaceCalculusFieldElement<S extends CalculusFieldElement<S>>- Returns:
- sinh(this)
-
acos
default T acos()
Arc cosine operation.- Specified by:
acosin interfaceCalculusFieldElement<S extends CalculusFieldElement<S>>- Returns:
- acos(this)
-
ceil
default T ceil()
Get the smallest whole number larger than instance.- Specified by:
ceilin interfaceCalculusFieldElement<S extends CalculusFieldElement<S>>- Returns:
- ceil(this)
-
floor
default T floor()
Get the largest whole number smaller than instance.- Specified by:
floorin interfaceCalculusFieldElement<S extends CalculusFieldElement<S>>- Returns:
- floor(this)
-
rint
default T rint()
Get the whole number that is the nearest to the instance, or the even one if x is exactly half way between two integers.- Specified by:
rintin interfaceCalculusFieldElement<S extends CalculusFieldElement<S>>- Returns:
- a double number r such that r is an integer r - 0.5 ≤ this ≤ r + 0.5
-
ulp
default T ulp()
Compute least significant bit (Unit in Last Position) for a number.- Specified by:
ulpin interfaceCalculusFieldElement<S extends CalculusFieldElement<S>>- Returns:
- ulp(this)
-
sign
default T sign()
Compute the sign of the instance. The sign is -1 for negative numbers, +1 for positive numbers and 0 otherwise, for Complex number, it is extended on the unit circle (equivalent to z/|z|, with special handling for 0 and NaN)- Specified by:
signin interfaceCalculusFieldElement<S extends CalculusFieldElement<S>>- Returns:
- -1.0, -0.0, +0.0, +1.0 or NaN depending on sign of a
-
getExponent
default int getExponent()
Return the exponent of the instance, removing the bias.For double numbers of the form 2x, the unbiased exponent is exactly x.
- Specified by:
getExponentin interfaceCalculusFieldElement<S extends CalculusFieldElement<S>>- Returns:
- exponent for the instance, without bias
-
-