SuanShu, a Java numerical and statistical library

com.numericalmethod.suanshu.analysis.function.rn2r1
Class BivariateRealFunction

java.lang.Object
  extended by com.numericalmethod.suanshu.analysis.function.rn2r1.BivariateRealFunction
All Implemented Interfaces:
Function, RealScalarFunction
Direct Known Subclasses:
AutoCorrelationFunction, AutoCovarianceFunction, Beta, DBeta, GammaLowerIncomplete, GammaRegularizedP, GammaRegularizedPInverse, GammaRegularizedQ, GammaUpperIncomplete, LogBeta

public abstract class BivariateRealFunction
extends java.lang.Object
implements RealScalarFunction

This abstract class represents a bivariate real function. It takes two real arguments and outputs one real value.

That is,

 y = f(x1, x2)
 


Nested Class Summary
 
Nested classes/interfaces inherited from interface com.numericalmethod.suanshu.analysis.function.Function
Function.EvaluationException
 
Constructor Summary
BivariateRealFunction()
           
 
Method Summary
 int dimension4Domain()
          Get the number of variables of the function.
 int dimension4Range()
          Get the dimension of the range space the function.
 double evaluate(double... x)
          A real function, f, takes a double array double[], {x0, x1, ..., xn} and maps it to a double, f(x0, x1, ..., xn)
abstract  double evaluate(double x1, double x2)
          Compute f(x1, x2).
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BivariateRealFunction

public BivariateRealFunction()
Method Detail

dimension4Domain

public int dimension4Domain()
Description copied from interface: Function
Get the number of variables of the function.

For example, for a univariate function, the domain dimension is 1. For a bivariate function, the domain dimension is 2.

Specified by:
dimension4Domain in interface Function
Returns:
the number of variables

dimension4Range

public int dimension4Range()
Description copied from interface: Function
Get the dimension of the range space the function.

For example, for a Rn->Rm function, the dimension of the range is m.

Specified by:
dimension4Range in interface Function
Returns:
the dimension of the range

evaluate

public double evaluate(double... x)
Description copied from interface: RealScalarFunction
A real function, f, takes a double array double[],
{x0, x1, ..., xn}
and maps it to a double,
f(x0, x1, ..., xn)

Specified by:
evaluate in interface RealScalarFunction
Parameters:
x - {x} = {x0, x1, ... xn}
Returns:
f({x}) as output

evaluate

public abstract double evaluate(double x1,
                                double x2)
Compute f(x1, x2).

Parameters:
x1 - x1
x2 - x2
Returns:
f(x1, x2)

SuanShu, a Java numerical and statistical library

Copyright © 2011 Numerical Method Inc. Ltd. All Rights Reserved.