Contains arrays for each function which contain a key 'func' which contains a GraphFunction instance, and a key 'color' which contains the color identifier to use when drawin the function.
Adds a function that should be displayed in the graph.
Tags:
access:
public
Parameters:
string
$name
The name of the function.
array
$function
A strict function where the key is the function's parameter and the corresponding value is the function's value for the parameter. Both the parameters and key have to be numerical.
string
$color
The identifier for the color that should be used when drawing the function.
Constructs and retrieves an image resource representing the graph.
Tags:
return:
An image resource with the graph on it.
access:
public
Parameters:
string
$backgroundColor
The identifier for the color that should be used for the background. The default is white.
string
$axisColor
The identifier for the color that should be used for the axis. The default is black.
array
$paramMarkers
The parameter values that should be marked and labeled on the axes.
array
$valueMarkers
The function values that should be marked and labeled on the axes.
callback
$paramNameCallback
An optional callback which is used when labeling the parameters.
callback
$valueNameCallback
An optional callback which is used when labeling the values.
array
$viewport
Specifies the viewport for graph. I.e. the minimum and maximum values and paramters that should be allowed in the graph. There are are four keys: 'valMin', 'valMax', 'paramMin', 'paramMax'. I.e. min value, max value, min param and max param.
string
$gridColor
The identifier for the color that should be used for the grids. The default is black.
boolean
$xGrid
True if the x axel should show a grid, false otherwise.
boolean
$yGrid
True if the y axel should show a grid, false otherwise.