Package com.imsl.test.example.math
Class MinUnconEx2
java.lang.Object
com.imsl.test.example.math.MinUnconEx2
- All Implemented Interfaces:
MinUncon.Derivative,MinUncon.Function
MinUncon Example 2: Minimizes a single variable function using the analytic derivative.
The minimum of \(e^x - 5x\) is found using function evaluations and first derivative evaluations.-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
MinUnconEx2
public MinUnconEx2()
-
-
Method Details
-
f
public double f(double x) Description copied from interface:MinUncon.FunctionPublic interface for the smooth function of a single variable to be minimized.- Specified by:
fin interfaceMinUncon.Function- Parameters:
x- adouble, the point at which the function is to be evaluated- Returns:
- a
double, the value of the function at x
-
g
public double g(double x) Description copied from interface:MinUncon.DerivativePublic interface for the smooth function of a single variable to be minimized.- Specified by:
gin interfaceMinUncon.Derivative- Parameters:
x- adouble, the point at which the derivative of the function is to be evaluated- Returns:
- a
double, the value of the derivative of the function at x
-
main
-