- All Implemented Interfaces:
DoubleBinaryOperator
,RealValuedFunctTwoOps
,RealValuedFunctVAOps
,VADomainOps
- Direct Known Subclasses:
BicubicInterpolator
,BicubicTriangleInterp
A subclass will typically override one or more of the methods valueAt, deriv1At, deriv2At, deriv11At, deriv12At, deriv21At, and deriv22At to provide the values for a function and its first and second partial derivative. For any that are not available, an UnsupportedOperationException will be thrown.
The class also provides scripting-language support. If a Scripting
context is named scripting
, the following EMCAScript
code will implement a function and its derivatives:
Alternatively, one may use the following code where the functions defining the derivatives are provided by name:importClass(org.bzdev.RealValuedFunctionTwo); .... // assume ourObject is a Java class with a method setFunction // that takes a RealValuedFunctionTwo as its argument. funct = new RealValuedFunctionTwo(scripting, {valueAt: function(x,y) {return Math.sin(x) * Math.cos(y);}, deriv1At: function(x,y) {return Math.cos(x) * Math.cos(y);}, deriv2At: function(x,y) {return -Math.sin(x) * Math.sin(y);}, deriv11At: function(x,y) {return -Math.sin(x) * Math.cos(y);}, deriv12At: function(x,y) {return -Math.cos(x) * Math.sin(y);}, deriv21At: function(x,y) {return -Math.cos(x) * Math.sin(y);}, deriv22At: function(x,y) {return -Math.sin(x) * Math.cos(y);} }; ourObject.setFunction(funct);
importClass(org.bzdev.RealValuedFunctionTwo); ... function f(x,y) {return Math.sin(x) * Math.cos(y);} function f1(x,y) {return Math.cos(x) * Math.cos(y);} function f2(x,y) {return -Math.sin(x) * Math.sin(y);} function f11(x,y) {return -Math.sin(x) * Math.cos(y);} function f12(x,y) {return -Math.cos(x) * Math.sin(y);} function f21(x,y) {return -Math.cos(x) * Math.sin(y);} function f22(x,y) {return -Math.sin(x) * Math.cos(y);} ... // assume ourObject is a Java class with a method setFunction // that takes a RealValuedFunction as its argument. funct = new RealValuedFunction(scripting, "f", "f1", "f2", "f11", "f12", "f21", "f22"); ourObject.setFunction(funct);
-
Nested Class Summary
Nested classes/interfaces inherited from class org.bzdev.math.RealValuedFunctionVA
RealValuedFunctionVA.Linear
-
Constructor Summary
ConstructorsConstructorDescriptionConstructor.RealValuedFunctionTwo
(RealValuedFunctTwoOps function) Constructor given a function that determines its value.RealValuedFunctionTwo
(RealValuedFunctTwoOps function, RealValuedFunctTwoOps function1, RealValuedFunctTwoOps function2) Constructor given functions that determines its value and its first partial derivatives.RealValuedFunctionTwo
(RealValuedFunctTwoOps function, RealValuedFunctTwoOps function1, RealValuedFunctTwoOps function2, RealValuedFunctTwoOps function11, RealValuedFunctTwoOps function12, RealValuedFunctTwoOps function21, RealValuedFunctTwoOps function22) Constructor given functions that determines its value and its first and second partial derivatives The arguments implementRealValuedFunctTwoOps
and can be a lambda expression with two arguments.RealValuedFunctionTwo
(ScriptingContext scriptingContext, Object object) Constructor when the function is provided by a script object.RealValuedFunctionTwo
(ScriptingContext scriptingContext, String fname, String f1name, String f2name) Constructor when the function and its first partial derivatives are provided by a script.RealValuedFunctionTwo
(ScriptingContext scriptingContext, String fname, String f1name, String f2name, String f11name, String f12name, String f21name, String f22name) Constructor when the function and its first and second partial derivatives are provided by a script. -
Method Summary
Modifier and TypeMethodDescriptionfinal RealValuedFunctTwoOps
deriv
(int i) Get a function that computes the value of partial derivative that would be computed by callingderivAt(int,double...)
.deriv1()
Get a function computing $\frac{\partial f}{\partial x_1}$.deriv11()
Get a function that computes $\frac{\partial^2 f}{\partial x_1^2}$ where f is this function.double
deriv11At
(double arg1, double arg2) Evaluate the partial derivative $ \frac{\partial^2 f}{\partial x_1^2}$ for a function f(x1,x2).deriv12()
Get a function that computes $\frac{\partial^2 f}{\partial x_1 \partial x_2}$ where f is this function.double
deriv12At
(double arg1, double arg2) Evaluate the partial derivative $\frac{\partial^2 f}{\partial x_1 \partial x_2}$ for a function f(x1,x2).double
deriv1At
(double arg1, double arg2) Evaluate the partial derivative $\frac{\partial f}{\partial x_1}$ for a function f(x1, x2).deriv2()
Get a function computing $\frac{\partial f}{\partial x_2}$.deriv21()
Get a function that computes $\frac{\partial^2 f}{\partial x_2 \partial x_1}$ where f is this function.double
deriv21At
(double arg1, double arg2) Evaluate the partial derivative $\frac{\partial^2 f}{\partial x_2 \partial x_1}$ for a function f(x1,x2).deriv22()
Get a function that computes $\frac{\partial^2 f}{\partial x_2^2}$ where f is this function.double
deriv22At
(double arg1, double arg2) Evaluate the partial derivative $\frac{\partial^2 f}{\partial x_2^2}$ for a function f(x1,x2).double
deriv2At
(double arg1, double arg2) Evaluate the partial derivative $\frac{\partial f}{\partial x_2}$ for a function f(x1,x2).final double
derivAt
(int i, double... args) Evaluate the partial derivative $\frac{\partial f}{\partial x_i}$ for a function f(x0,x1, ...).boolean
Determine if the domain maximum for the first argument is in the domain.boolean
Determine if the domain maximum for the second argument is in the domain.final boolean
domainMaxClosed
(int i) Determine if the domain maximum for the ith argument, when the arguments are in the domain of the function, is in the function's domain.boolean
Determine if the domain minimum for the first argument is in the domain.boolean
Determine if the domain minimum for the second argument is in the domain.final boolean
domainMinClosed
(int i) Determine if the domain minimum for the ith argument, when the arguments are in the domain of the function, is in the function's domain.final double
getDomainMax
(int i) Get the least upper bound of the ith argument when the arguments are in the domain of the function.double
Get the maximum value of the first argument in the domain of the function.double
Get the maximum value of the second argument in the domain of the function.final double
getDomainMin
(int i) Get the greatest lower bound of the ith argument when the arguments are in the domain of the function.double
Get the minimum value of the first argument in the domain of the function.double
Get the minimum value of the second argument in the domain of the function.final boolean
isInDomain
(double... args) Determine if a point is within the domain of this function.boolean
isInDomain
(double x, double y) Determine if a point (x, y) is within the domain of a real-valued function of two arguments.final RealValuedFunctTwoOps
secondDeriv
(int i, int j) Get a function that computes the value of the second partial derivative that would be computed by callingsecondDerivAt(int,int,double...)
.final double
secondDerivAt
(int i, int j, double... args) Evaluate the partial derivative $\frac{\partial^2 f}{\partial x_i \partial z_j}$ for a function f(x0,x1, ...).final double
valueAt
(double... args) Call the function.double
valueAt
(double arg1, double arg2) Call the function.Methods inherited from class org.bzdev.math.RealValuedFunctionVA
jacobian, jacobian, maxArgLength, minArgLength
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.bzdev.math.RealValuedFunctTwoOps
applyAsDouble, maxArgLength, minArgLength
-
Constructor Details
-
RealValuedFunctionTwo
public RealValuedFunctionTwo()Constructor. -
RealValuedFunctionTwo
Constructor given a function that determines its value. The argument implementsRealValuedFunctTwoOps
and can be a lambda expression with two arguments. The interfaceRealValuedFunctTwoOps
provides a single method:RealValuedFunctTwoOps.valueAt(double,double)
that, when called, provides the function's value.- Parameters:
function
- the function providing the value for the method valueAt; null if the valueAt method is not supported
-
RealValuedFunctionTwo
public RealValuedFunctionTwo(RealValuedFunctTwoOps function, RealValuedFunctTwoOps function1, RealValuedFunctTwoOps function2) Constructor given functions that determines its value and its first partial derivatives. The arguments implementRealValuedFunctTwoOps
and can be a lambda expression with two arguments. The interfaceRealValuedFunctTwoOps
provides a single method:RealValuedFunctTwoOps.valueAt(double,double)
that, when called, provides the function's value.- Parameters:
function
- the function providing the value for the method valueAt; null if the valueAt method is not supportedfunction1
- the function providing the value for the method {#link #deriv1At(double,double)}; null if the deriv1At method is not supportedfunction2
- the function providing the value for the method {#link #deriv2At(double,double)}; null if the deriv2At method is not supported
-
RealValuedFunctionTwo
public RealValuedFunctionTwo(RealValuedFunctTwoOps function, RealValuedFunctTwoOps function1, RealValuedFunctTwoOps function2, RealValuedFunctTwoOps function11, RealValuedFunctTwoOps function12, RealValuedFunctTwoOps function21, RealValuedFunctTwoOps function22) Constructor given functions that determines its value and its first and second partial derivatives The arguments implementRealValuedFunctTwoOps
and can be a lambda expression with two arguments. The interfaceRealValuedFunctTwoOps
provides a single method:RealValuedFunctTwoOps.valueAt(double,double)
that, when called, provides the function's value.- Parameters:
function
- the function providing the value for the method valueAt; null if the valueAt method is not supportedfunction1
- the function providing the value for the methodderiv1At(double,double)
; null if the deriv1At method is not supportedfunction2
- the function providing the value for the methodderiv2At(double,double)
; null if the deriv2At method is not supportedfunction11
- the function providing the value for the methodderiv11At(double,double)
; null if the deriv11At method is not supportedfunction12
- thea function providing the value for the methodderiv12At(double,double)
; null if the deriv12At method is not supportedfunction21
- the function providing the value for the methodderiv21At(double,double)
; null if the deriv21At method is not supportedfunction22
- the function providing the value for the methodderiv22At(double,double)
; null if the deriv22At method is not supported
-
RealValuedFunctionTwo
Constructor when the function is provided by a script object. The parameter 'object' is expected to be either an instance of RealValuedFunctionTwo or an object defined by a scripting language with methods named "valueAt", "deriv1At" "deriv2At", "deriv11At", "deriv12At", deriv21At", and "deriv22At". Each of these methods takes two arguments, both real numbers, and returns a number. For a real-valued function f(x1,x2), these methods are defined as follows:valueAt
returns f(x1,x2).deriv1At
returns ∂f/∂x1 evaluated at the point (x1,x2).deriv2At
returns ∂f/∂x2 evaluated at the point (x1,x2).deriv11At
returns ∂2f/∂x12 evaluated at the point (x1,x2).deriv12At
returns ∂2f/∂x1∂x2 evaluated at the point (x1,x2).deriv21At
returns ∂2f/∂x2∂x1 evaluated at the point (x1,x2).deriv22At
returns ∂2f/∂x12 evaluated at the point (x1,x2).
- Parameters:
scriptingContext
- the scripting contextobject
- an object from a scripting environment defining the methods defined above or a subset of those methods
-
RealValuedFunctionTwo
public RealValuedFunctionTwo(ScriptingContext scriptingContext, String fname, String f1name, String f2name) Constructor when the function and its first partial derivatives are provided by a script. The script is expected to define up to three functions, indicated by their names.- Parameters:
scriptingContext
- the scripting contextfname
- the name of a function providing the value for the method valueAt; null if the valueAt method is not supportedf1name
- the name of a function providing the value for the methodderiv1At(double,double)
; null if the deriv1At method is not supportedf2name
- the name of a function providing the value for the methodderiv2At(double,double)
; null if the deriv2At method is not supported
-
RealValuedFunctionTwo
public RealValuedFunctionTwo(ScriptingContext scriptingContext, String fname, String f1name, String f2name, String f11name, String f12name, String f21name, String f22name) Constructor when the function and its first and second partial derivatives are provided by a script. The script is expected to define up to seven functions, indicated by their names.- Parameters:
scriptingContext
- the scripting contextfname
- the name of a function providing the value for the method valueAt; null if the valueAt method is not supportedf1name
- the name of a function providing the value for the methodderiv1At(double,double)
; null if the deriv1At method is not supportedf2name
- the name of a function providing the value for the methodderiv2At(double,double)
; null if the deriv2At method is not supportedf11name
- the name of a function providing the value for the methodderiv11At(double,double)
; null if the deriv11At method is not supportedf12name
- the name of a function providing the value for the methodderiv12At(double,double)
; null if the deriv12At method is not supportedf21name
- the name of a function providing the value for the methodderiv21At(double,double)
; null if the deriv21At method is not supportedf22name
- the name of a function providing the value for the methodderiv22At(double,double)
; null if the deriv22At method is not supported
-
-
Method Details
-
getDomainMin
Description copied from class:RealValuedFunctionVA
Get the greatest lower bound of the ith argument when the arguments are in the domain of the function. The implementation will either return the most negative double-precision number or the result of calling a method named getDomainMin (with the same arguments as this method) provided by an object created by a scripting language. If an object created via a scripting language is not passed to a constructor, and a different value is appropriate, this method should be overridden.- Specified by:
getDomainMin
in interfaceVADomainOps
- Overrides:
getDomainMin
in classRealValuedFunctionVA
- Parameters:
i
- the index determining the argument for which this method applies (0th, 1st, ...)- Returns:
- the minimum value
- Throws:
IllegalArgumentException
- the argument is out of rangeIllegalStateException
- the function was not fully initialized.
-
getDomainMax
Description copied from class:RealValuedFunctionVA
Get the least upper bound of the ith argument when the arguments are in the domain of the function. The implementation will either return the largest double-precision number or the result of calling a method named getDomainMax (with the same arguments as this method) provided by an object created by a scripting language. If an object created via a scripting language is not passed to a constructor, and a different value is appropriate, this method should be overridden.- Specified by:
getDomainMax
in interfaceVADomainOps
- Overrides:
getDomainMax
in classRealValuedFunctionVA
- Parameters:
i
- the index determining the argument for which this method applies (0th, 1st, ...)- Returns:
- the maximum value
- Throws:
IllegalArgumentException
- the argument is out of rangeIllegalStateException
- the function was not fully initialized.
-
domainMinClosed
Description copied from class:RealValuedFunctionVA
Determine if the domain minimum for the ith argument, when the arguments are in the domain of the function, is in the function's domain. The implementation will either return true or the result of calling a method named getDomainMinClosed (with the same arguments as this method) provided by an object created by a scripting language. If an object created via a scripting language is not passed to a constructor, and a different value is appropriate, this method should be overridden.- Specified by:
domainMinClosed
in interfaceVADomainOps
- Overrides:
domainMinClosed
in classRealValuedFunctionVA
- Parameters:
i
- the index determining the argument for which this method applies (0th, 1st, ...)- Returns:
- true if the domain minimum is in the domain; false if it is the greatest lower bound for the domain
- Throws:
IllegalArgumentException
- the argument is out of rangeIllegalStateException
- the function was not fully initialized.
-
domainMaxClosed
Description copied from class:RealValuedFunctionVA
Determine if the domain maximum for the ith argument, when the arguments are in the domain of the function, is in the function's domain. The implementation will either return true or the result of calling a method named getDomainMaxClosed (with the same arguments as this method) provided by an object created by a scripting language. If an object created via a scripting language is not passed to a constructor, and a different value is appropriate, this method should be overridden.- Specified by:
domainMaxClosed
in interfaceVADomainOps
- Overrides:
domainMaxClosed
in classRealValuedFunctionVA
- Parameters:
i
- the index determining the argument for which this method applies (0th, 1st, ...)- Returns:
- true if the domain maximum is in the domain; false if it is the least upper bound for the domain
- Throws:
IllegalArgumentException
- the argument is out of rangeIllegalStateException
- the function was not fully initialized.
-
getDomainMin1
Get the minimum value of the first argument in the domain of the function.- Returns:
- the minimum value
- Throws:
IllegalStateException
- the function was not fully initialized.
-
getDomainMax1
Get the maximum value of the first argument in the domain of the function.- Returns:
- the maximum value
- Throws:
IllegalStateException
- the function was not fully initialized.
-
getDomainMin2
Get the minimum value of the second argument in the domain of the function.- Returns:
- the minimum value
- Throws:
IllegalStateException
- the function was not fully initialized.
-
getDomainMax2
Get the maximum value of the second argument in the domain of the function.- Returns:
- the maximum value
- Throws:
IllegalStateException
- the function was not fully initialized.
-
domainMin1Closed
Determine if the domain minimum for the first argument is in the domain.- Returns:
- true if the domain minimum is in the domain; false if it is the greatest lower bound for the domain
- Throws:
IllegalStateException
- the function was not fully initialized.
-
domainMax1Closed
Determine if the domain maximum for the first argument is in the domain.- Returns:
- true if the domain maximum is in the domain; false if it is the least upper bound for the domain
- Throws:
IllegalStateException
- the function was not fully initialized.
-
domainMin2Closed
Determine if the domain minimum for the second argument is in the domain.- Returns:
- true if the domain minimum is in the domain; false if it is the greatest lower bound for the domain
- Throws:
IllegalStateException
- the function was not fully initialized.
-
domainMax2Closed
Determine if the domain maximum for the second argument is in the domain.- Returns:
- true if the domain maximum is in the domain; false if it is the least upper bound for the domain
- Throws:
IllegalStateException
- the function was not fully initialized.
-
isInDomain
public final boolean isInDomain(double... args) throws UnsupportedOperationException, IllegalArgumentException, IllegalStateException Description copied from class:RealValuedFunctionVA
Determine if a point is within the domain of this function.The default behavior of this method assumes the domain is a rectangular region and uses the methods
RealValuedFunctionVA.getDomainMin(int)
,RealValuedFunctionVA.getDomainMax(int)
,RealValuedFunctionVA.domainMinClosed(int)
,RealValuedFunctionVA.domainMaxClosed(int)
, to determine if the arguments represent a point in the functions domain. If the domain is not rectangular with each side either in or not in the domain, then this method must be overridden. If it is not possible with a reasonable amount of computation to determine that a point is in the domain, an UnsupportedOperationException may be thrown. If this exception is thrown, it should be thrown regardless of the arguments.- Specified by:
isInDomain
in interfaceVADomainOps
- Overrides:
isInDomain
in classRealValuedFunctionVA
- Parameters:
args
- the arguments (x0,x1,...) giving the coordinates of a point- Returns:
- true if the point (x0,x1,...) is in this function's domain; false otherwise
- Throws:
UnsupportedOperationException
- domain membership could not be determined.IllegalArgumentException
- an argument is out of rangeIllegalStateException
- the function was not fully initialized.
-
isInDomain
public boolean isInDomain(double x, double y) throws UnsupportedOperationException, IllegalStateException Determine if a point (x, y) is within the domain of a real-valued function of two arguments.The default behavior of this method assumes the domain is a rectangular region and uses the methods
getDomainMin1()
,getDomainMin2()
,getDomainMax1()
,getDomainMax2()
domainMin1Closed()
,domainMin2Closed()
,domainMax1Closed()
, anddomainMax2Closed()
to determine if the arguments represent a point in the functions domain. If the domain is not rectangular with each side either in or not in the domain, then this method must be overridden. If it is not possible with a reasonable amount of computation to determine that a point is in the domain, an UnsupportedOperationException may be thrown. If this exception is thrown, it should be thrown regardless of the arguments.- Parameters:
x
- the 1st coordinatey
- the 2nd coordinate- Returns:
- true if the point (x, y) is in this function's domain; false otherwise
- Throws:
UnsupportedOperationException
- domain membership could not be determined.IllegalStateException
- the function was not fully initialized.
-
valueAt
public final double valueAt(double... args) throws IllegalArgumentException, UnsupportedOperationException Description copied from class:RealValuedFunctionVA
Call the function.- Specified by:
valueAt
in interfaceRealValuedFunctTwoOps
- Specified by:
valueAt
in interfaceRealValuedFunctVAOps
- Overrides:
valueAt
in classRealValuedFunctionVA
- Parameters:
args
- the function's arguments- Returns:
- the value of the function for the given arguments
- Throws:
IllegalArgumentException
- the function's argument(s) were out of rangeUnsupportedOperationException
- the operation is not supported.
-
valueAt
public double valueAt(double arg1, double arg2) throws IllegalArgumentException, UnsupportedOperationException, IllegalStateException Call the function.- Specified by:
valueAt
in interfaceRealValuedFunctTwoOps
- Parameters:
arg1
- the function's first argumentarg2
- the function's second argument- Returns:
- the value of the function for the given arguments
- Throws:
IllegalArgumentException
- the function's argument(s) were out of rangeUnsupportedOperationException
- the operation is not supported.IllegalStateException
- the function was not fully initialized.
-
deriv
Get a function that computes the value of partial derivative that would be computed by callingderivAt(int,double...)
.- Parameters:
i
- an index in the range [0, 1] indicating the argument with which to differentiate- Returns:
- the function
-
derivAt
public final double derivAt(int i, double... args) throws IllegalArgumentException, UnsupportedOperationException, IllegalStateException Evaluate the partial derivative $\frac{\partial f}{\partial x_i}$ for a function f(x0,x1, ...).This method calls a method named
deriv
<i+1>At(...)
wherei
is the value of the first argument of this method. One should usually override those methods (for (i+1) in [1,2]) instead of this one.- Overrides:
derivAt
in classRealValuedFunctionVA
- Parameters:
i
- the index indicating that the partial derivative is computed for the ith argument, numbered from zeroargs
- the function f's arguments- Returns:
- the value of the partial derivative for the given argument
- Throws:
IllegalArgumentException
- the function's argument(s) were out of rangeUnsupportedOperationException
- the operation is not supported.IllegalStateException
- the function was not fully initialized.
-
deriv1
Get a function computing $\frac{\partial f}{\partial x_1}$.- Returns:
- a function that computes $\frac{\partial f}{\partial x_1}$
-
deriv1At
public double deriv1At(double arg1, double arg2) throws IllegalArgumentException, UnsupportedOperationException, IllegalStateException Evaluate the partial derivative $\frac{\partial f}{\partial x_1}$ for a function f(x1, x2).- Parameters:
arg1
- the function's first argumentarg2
- the function's second argument- Returns:
- the value of the partial derivative for the given argument
- Throws:
IllegalArgumentException
- the function's argument(s) were out of rangeUnsupportedOperationException
- the operation is not supported.IllegalStateException
- the function was not fully initialized.
-
deriv2
Get a function computing $\frac{\partial f}{\partial x_2}$.- Returns:
- a function that computes $\frac{\partial f}{\partial x_2}$
-
deriv2At
public double deriv2At(double arg1, double arg2) throws IllegalArgumentException, UnsupportedOperationException, IllegalStateException Evaluate the partial derivative $\frac{\partial f}{\partial x_2}$ for a function f(x1,x2).- Parameters:
arg1
- the function's first argumentarg2
- the function's second argument- Returns:
- the value of the partial derivative for the given argument
- Throws:
IllegalArgumentException
- the function's argument(s) were out of rangeUnsupportedOperationException
- the operation is not supported.IllegalStateException
- the function was not fully initialized.
-
secondDeriv
Get a function that computes the value of the second partial derivative that would be computed by callingsecondDerivAt(int,int,double...)
.- Parameters:
i
- the index of the argument for the first differentiationj
- the index of the argument for the second differentiation- Returns:
- the function
-
secondDerivAt
public final double secondDerivAt(int i, int j, double... args) throws IllegalArgumentException, UnsupportedOperationException, IllegalStateException Evaluate the partial derivative $\frac{\partial^2 f}{\partial x_i \partial z_j}$ for a function f(x0,x1, ...).This method calls a method named deriv
<
i+1><
j+1<At(...) where i and j are the values of the first two arguments. One should usually override those methods instead of this one.- Overrides:
secondDerivAt
in classRealValuedFunctionVA
- Parameters:
i
- the index indicating that the partial derivative is computed for the ith argument, numbered from 0j
- the index indicating that the partial derivative is computed for the jth argument, numbered from 0args
- the function f's arguments- Returns:
- the value of the partial derivative $\frac{\partial^2 f}{\partial x_i \partial z_j}$ for the given arguments x0, x1, ...
- Throws:
IllegalArgumentException
- the function's arguments were out of rangeUnsupportedOperationException
- the operation is not supported.IllegalStateException
- the function was not fully initialized.
-
deriv11
Get a function that computes $\frac{\partial^2 f}{\partial x_1^2}$ where f is this function.- Returns:
- a function that computes $\frac{\partial^2 f}{\partial x_1^2}$
-
deriv11At
public double deriv11At(double arg1, double arg2) throws IllegalArgumentException, UnsupportedOperationException, IllegalStateException Evaluate the partial derivative $ \frac{\partial^2 f}{\partial x_1^2}$ for a function f(x1,x2).- Parameters:
arg1
- the function's first argumentarg2
- the function's second argument- Returns:
- the value of the partial derivative for the given argument
- Throws:
IllegalArgumentException
- the function's argument(s) were out of rangeUnsupportedOperationException
- the operation is not supported.IllegalStateException
- the function was not fully initialized.
-
deriv12
Get a function that computes $\frac{\partial^2 f}{\partial x_1 \partial x_2}$ where f is this function.- Returns:
- a function that computes $\frac{\partial^2 f}{\partial x_1 \partial x_2}$
-
deriv12At
public double deriv12At(double arg1, double arg2) throws IllegalArgumentException, UnsupportedOperationException, IllegalStateException Evaluate the partial derivative $\frac{\partial^2 f}{\partial x_1 \partial x_2}$ for a function f(x1,x2).- Parameters:
arg1
- the function's first argumentarg2
- the function's second argument- Returns:
- the value of the partial derivative for the given argument
- Throws:
IllegalArgumentException
- the function's argument(s) were out of rangeUnsupportedOperationException
- the operation is not supported.IllegalStateException
- the function was not fully initialized.
-
deriv21
Get a function that computes $\frac{\partial^2 f}{\partial x_2 \partial x_1}$ where f is this function.- Returns:
- a function that computes $\frac{\partial^2 f}{\partial x_2 \partial x_1}$
-
deriv21At
public double deriv21At(double arg1, double arg2) throws IllegalArgumentException, UnsupportedOperationException, IllegalStateException Evaluate the partial derivative $\frac{\partial^2 f}{\partial x_2 \partial x_1}$ for a function f(x1,x2).- Parameters:
arg1
- the function's first argumentarg2
- the function's second argument- Returns:
- the value of the partial derivative for the given argument
- Throws:
IllegalArgumentException
- the function's argument(s) were out of rangeUnsupportedOperationException
- the operation is not supported.IllegalStateException
- the function was not fully initialized.
-
deriv22
Get a function that computes $\frac{\partial^2 f}{\partial x_2^2}$ where f is this function.- Returns:
- a function that computes $\frac{\partial^2 f}{\partial x_2^2}$
-
deriv22At
public double deriv22At(double arg1, double arg2) throws IllegalArgumentException, UnsupportedOperationException, IllegalStateException Evaluate the partial derivative $\frac{\partial^2 f}{\partial x_2^2}$ for a function f(x1,x2).- Parameters:
arg1
- the function's first argumentarg2
- the function's second argument- Returns:
- the value of the partial derivative for the given argument
- Throws:
IllegalArgumentException
- the function's argument(s) were out of rangeUnsupportedOperationException
- the operation is not supported.IllegalStateException
- the function was not fully initialized.
-