C2Function Class Reference

Inheritance diagram for C2Function:

_fC2cos _fC2exp _fC2identity _fC2log _fC2sin _fC2sqrt C2BinaryFunction C2ComposedFunction C2ConnectorFunction C2Constant C2InverseFunction C2Linear C2Polynomial C2PowerLaw C2Quadratic C2ScaledFunction C2ScaledRecip InterpolatingFunction gauss lorentz

List of all members.


Detailed Description

Provides support for the entire C2Function hierarchy.

Definition at line 88 of file C2Functions.py.


Public Member Functions

def __init__
def __str__
def SetName
def value_with_derivatives
 get the value of the function, and its first & second derivative
def __call__
def apply
def find_root
def SetDomain
 Set the domain of the function to (xmin, xmax). Mostly, the domain is informative, and used by other functions to figure out where the function should be applied. many functions can be evaluated without error outside their marked domain. However, some functions for which it is wrong to do so (InterpolatingFunction, e.g.) will raise an exception.
def GetDomain
 get a tuple of the domain of the function
def compose
 return the value of self(inner_function(x)) without explicitly creating a composed function
def convert_arg
 utility to make sure python constants get converted to C2Constant objects in subclasses
def __add__
 Python operator to return a function self +right.
def __sub__
 Python operator to return a function self -right.
def __mul__
 Python operator to return a function self *right.
def __div__
 Python operator to return a function self /right.
def __pow__
 Python operator to return a function self ^right.
def partial_integrals
 For points in recur_data, compute {$ \int_{x_i}^{x_{i+1}} f(x) dx $} .
def SetSamplingGrid
 give a C2Function hints about interesting points to sample for integration, etc.
def GetSamplingGrid
 Extract the list of 'interesting' points from the sampling grid which lie in the requested domain, including q point at each endpoint.
def integral
 return the definite integral from xmin to xmax of this function using our sampling_grid for hints.
def NormalizedFunction
 return a new C2Function which has integral norm on (xmin, xmax )
def SquareNormalizedFunction
 return a new C2Function which has square-integral norm on (xmin, xmax ) with weight function weight

Public Attributes

 xMax
 xMin
 sampling_grid
 name
 total_func_evals

Static Public Attributes

string ClassName = 'C2Function'
string name = 'Unnamed'

The documentation for this class was generated from the following file:
Generated on Wed Nov 21 10:18:31 2007 for analysis by  doxygen 1.5.4