| IGLib 1.6.0 The IGLib base library for development of numerical, technical and business applications.

- Main Page
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Events
Public Member Functions | Properties | List of all members
IG.Num.IScalarFunctionResults Interface Reference

Storage for results of a scalar function. Includes parameters at which function was (or should be) evaluated, flags specifying what has been and what should be evaluated, calculated value, gradient and Hessian of the function in the specified point. More...

Inheritance diagram for IG.Num.IScalarFunctionResults:
[legend]

## Public Member Functions
IVector | GetParameters ()
| Returns vector of optimization parameters. More...
void | SetParameters (IVector value)
| Sets the vector of optimization parameters. If CopyReferences=true (false by default) then only the reference is copied. More...
void | SetParametersReference (IVector reference)
| Sets the vector of optimization parameters. Only the reference is copied. More...
double | GetParameter (int index)
| Returns specific optimization parameter. Throws exception if not defined or index out of bounds. More...
void | SetParameter (int index, double value)
| Sets the specified optimization parameter. More...
double | GetValue ()
| Returns the value of the function./summary> More...
void | SetValue (double value)
| Sets the value of the function. More...
IVector | GetGradient ()
| Returns the function gradient. More...
void | SetGradient (IVector value)
| Sets the function gradient. If CopyReferences=true (false by default) then only the reference is copied. More...
void | SetGradientReference (IVector reference)
| Sets the function gradient. Only the reference is copied. More...
double | GetGradient (int index)
| Returns the specified component of the function gradient. More...
void | SetGradient (int index, double value)
| Sets the specified component of the function gradient. More...
IMatrix | GetHessian ()
| Returns the function's Hessian. More...
void | SetHessian (IMatrix value)
| Sets the functions' Hessian. If CopyReferences=true (false by default) then only the reference is copied. More...
void | SetHessianReference (IMatrix reference)
| Sets the functions' Hessian. Only the reference is copied. More...
double | GetHessian (int rowIndex, int columnIndex)
| Returns the specified component of the function;s Hessian. More...
void | SetHessian (int rowIndex, int columnIndex, double value)
| Sets the specified component of the function's Hessian. More...
void | NullifyAll ()
| Sets all objects (parameter and result objects) to null. If the references are not assigned elsewhere, these objects become eligible for garbage collection. More...
void | NullifyResults ()
| Sets all result objects to null. If the references are not assigned elsewhere, these objects become eligible for garbage collection. More...
void | AllocateParameters ()
| Allocates space for parameters. More...
void | AllocateRequested ()
| Allocates space for all requested result objects. More...
void | AllocateGradient ()
| Allocate space for function gradient. More...
void | AllocateHessian ()
| Allocates space for function Hessian. More...
void | ResetResults ()
| Sets all calculated flags to false, error code to 0 (no error) and error string to null. More...
void | Copy (IScalarFunctionResults results)
| Copies data from another analysis results. More...
IScalarFunctionResults | GetCopy ()
| Returns an exact deep copy of the current object. More...

## Properties
int | NumParameters`[get, set]`
| Number of parameters. More...
bool | CopyReferences`[get, set]`
| Indicates whether just references can be copied when setting function parameters or results. If false then deep copy is always be performed. Default is false. More...
IVector | Parameters`[get, set]`
| Optimization parameters. If CopyReferences=true (false by default) then only the reference is copied when assigning. More...
double | Value`[get, set]`
| Value of the function. More...
IVector | Gradient`[get, set]`
| Function gradient. If CopyReferences=true (false by default) then only the reference is copied in assignments. More...
IMatrix | Hessian`[get, set]`
| Function Hessian (matrix of second derivatives). If CopyReferences=true (false by default) then only the reference is copied in assignments. More...
bool | ReqValue`[get, set]`
| Indicates whether calculation of function value is/was requested. More...
bool | ReqGradient`[get, set]`
| Indicates whether calculation of function gradient is/was requested. More...
bool | ReqHessian`[get, set]`
| Indicates whether calculation of function Hessian is/was requested. More...
int | ErrorCode`[get, set]`
| Error code. 0 - everything is OK. negative value - something went wrong. More...
String | ErrorString`[get, set]`
| Error string indicating what went wrong. More...
bool | Calculated`[get, set]`
| Collectively gets or sets calculated flags. Set false: all calculated flags are set to false. Set true: all calculated flags for which the corresponding request flags are true, are set to truee, others are set to false. Get: returns true if all the flags for which the corresponding request flags are true, are also true. Otherwise returns false. More...
bool | CalculatedValue`[get, set]`
| Indicates whether calculation of function value is/was requested. More...
bool | CalculatedGradient`[get, set]`
| Indicates whether calculation of function gradient is/was requested. More...
bool | CalculatedHessian`[get, set]`
| Indicates whether calculation of function Hessian is/was requested. More...

## Detailed Description

Storage for results of a scalar function. Includes parameters at which function was (or should be) evaluated, flags specifying what has been and what should be evaluated, calculated value, gradient and Hessian of the function in the specified point.

$A Igor xx Dec09 Nov10;

## Member Function Documentation

IVector IG.Num.IScalarFunctionResults.GetParameters | ( |  | ) |

Returns vector of optimization parameters.

Implemented in IG.Num.ScalarFunctionResults.

void IG.Num.IScalarFunctionResults.SetParameters | ( | IVector | value | ) |

Sets the vector of optimization parameters. If CopyReferences=true (false by default) then only the reference is copied.

Parameters

  value | Value to be assigned.

Implemented in IG.Num.ScalarFunctionResults.

void IG.Num.IScalarFunctionResults.SetParametersReference | ( | IVector | reference | ) |

Sets the vector of optimization parameters. Only the reference is copied.

Parameters

  value | Reference to be assigned.

Implemented in IG.Num.ScalarFunctionResults.

double IG.Num.IScalarFunctionResults.GetParameter | ( | int | index | ) |

Returns specific optimization parameter. Throws exception if not defined or index out of bounds.

Parameters

  iindex | Index of parameter to be returned (counting from 0).

Implemented in IG.Num.ScalarFunctionResults.

void IG.Num.IScalarFunctionResults.SetParameter | ( | int | index,
|  | double | value
| ) |  |

Sets the specified optimization parameter.

Parameters

  index | Index of parameter to be set (counting from 0).
  value | Parameter value.

Implemented in IG.Num.ScalarFunctionResults.

double IG.Num.IScalarFunctionResults.GetValue | ( |  | ) |

Returns the value of the function./summary>

Implemented in IG.Num.ScalarFunctionResults.

void IG.Num.IScalarFunctionResults.SetValue | ( | double | value | ) |

Sets the value of the function.

Parameters

  value | Value to be assigned to the function.

Implemented in IG.Num.ScalarFunctionResults.

IVector IG.Num.IScalarFunctionResults.GetGradient | ( |  | ) |

Returns the function gradient.

Implemented in IG.Num.ScalarFunctionResults.

void IG.Num.IScalarFunctionResults.SetGradient | ( | IVector | value | ) |

Sets the function gradient. If CopyReferences=true (false by default) then only the reference is copied.

Parameters

  value | Value to be assigned.

Implemented in IG.Num.ScalarFunctionResults.

void IG.Num.IScalarFunctionResults.SetGradientReference | ( | IVector | reference | ) |

Sets the function gradient. Only the reference is copied.

Parameters

  value | Reference to be assigned.

Implemented in IG.Num.ScalarFunctionResults.

Referenced by IG.Num.ScalarFunctionUntransformedBase.Evaluate().

double IG.Num.IScalarFunctionResults.GetGradient | ( | int | index | ) |

Returns the specified component of the function gradient.

Parameters

  index | Index of the component.

Implemented in IG.Num.ScalarFunctionResults.

void IG.Num.IScalarFunctionResults.SetGradient | ( | int | index,
|  | double | value
| ) |  |

Sets the specified component of the function gradient.

Parameters

  index | Index of gradient component to be set.
  value | Value of the function gradient component.

Implemented in IG.Num.ScalarFunctionResults.

IMatrix IG.Num.IScalarFunctionResults.GetHessian | ( |  | ) |

Returns the function's Hessian.

Implemented in IG.Num.ScalarFunctionResults.

void IG.Num.IScalarFunctionResults.SetHessian | ( | IMatrix | value | ) |

Sets the functions' Hessian. If CopyReferences=true (false by default) then only the reference is copied.

Parameters

  value | Value to be assigned.

Implemented in IG.Num.ScalarFunctionResults.

void IG.Num.IScalarFunctionResults.SetHessianReference | ( | IMatrix | reference | ) |

Sets the functions' Hessian. Only the reference is copied.

Parameters

  value | Reference to be assigned.

Implemented in IG.Num.ScalarFunctionResults.

Referenced by IG.Num.ScalarFunctionUntransformedBase.Evaluate().

double IG.Num.IScalarFunctionResults.GetHessian | ( | int | rowIndex,
|  | int | columnIndex
| ) |  |

Returns the specified component of the function;s Hessian.

Parameters

  rowIndex | Row index of the component (counting from 0).
  columnIndex | Column index of the component (counting from 0).

Implemented in IG.Num.ScalarFunctionResults.

void IG.Num.IScalarFunctionResults.SetHessian | ( | int | rowIndex,
|  | int | columnIndex,
|  | double | value
| ) |  |

Sets the specified component of the function's Hessian.

Parameters

  rowIndex | Row index of the component (counting from 0).
  columnIndex | Column index of the component (counting from 0).
  value | Value to be assigned to Hessian.

Implemented in IG.Num.ScalarFunctionResults.

void IG.Num.IScalarFunctionResults.NullifyAll | ( |  | ) |

Sets all objects (parameter and result objects) to null. If the references are not assigned elsewhere, these objects become eligible for garbage collection.

Implemented in IG.Num.ScalarFunctionResults.

void IG.Num.IScalarFunctionResults.NullifyResults | ( |  | ) |

Sets all result objects to null. If the references are not assigned elsewhere, these objects become eligible for garbage collection.

Implemented in IG.Num.ScalarFunctionResults.

void IG.Num.IScalarFunctionResults.AllocateParameters | ( |  | ) |

Allocates space for parameters.

Implemented in IG.Num.ScalarFunctionResults.

void IG.Num.IScalarFunctionResults.AllocateRequested | ( |  | ) |

Allocates space for all requested result objects.

Implemented in IG.Num.ScalarFunctionResults.

void IG.Num.IScalarFunctionResults.AllocateGradient | ( |  | ) |

Allocate space for function gradient.

Implemented in IG.Num.ScalarFunctionResults.

void IG.Num.IScalarFunctionResults.AllocateHessian | ( |  | ) |

Allocates space for function Hessian.

Implemented in IG.Num.ScalarFunctionResults.

void IG.Num.IScalarFunctionResults.ResetResults | ( |  | ) |

Sets all calculated flags to false, error code to 0 (no error) and error string to null.

Implemented in IG.Num.ScalarFunctionResults.

void IG.Num.IScalarFunctionResults.Copy | ( | IScalarFunctionResults | results | ) |

Copies data from another analysis results.

Parameters

  res | Analysis results which data is copied from.

Implemented in IG.Num.ScalarFunctionResults.

IScalarFunctionResults IG.Num.IScalarFunctionResults.GetCopy | ( |  | ) |

Returns an exact deep copy of the current object.

Implemented in IG.Num.ScalarFunctionResults.

## Property Documentation

int IG.Num.IScalarFunctionResults.NumParameters
| get set

Number of parameters.

Referenced by IG.Num.ScalarFunctionResults.Copy().

bool IG.Num.IScalarFunctionResults.CopyReferences
| get set

Indicates whether just references can be copied when setting function parameters or results. If false then deep copy is always be performed. Default is false.

IVector IG.Num.IScalarFunctionResults.Parameters
| get set

Optimization parameters. If CopyReferences=true (false by default) then only the reference is copied when assigning.

Referenced by IG.Num.ScalarFunctionResults.Copy(), and IG.Num.ScalarFunctionUntransformedBase.Evaluate().

double IG.Num.IScalarFunctionResults.Value
| get set

Value of the function.

Referenced by IG.Num.ScalarFunctionResults.Copy(), and IG.Num.ScalarFunctionUntransformedBase.Evaluate().

IVector IG.Num.IScalarFunctionResults.Gradient
| get set

Function gradient. If CopyReferences=true (false by default) then only the reference is copied in assignments.

Referenced by IG.Num.ScalarFunctionResults.Copy(), and IG.Num.ScalarFunctionUntransformedBase.Evaluate().

IMatrix IG.Num.IScalarFunctionResults.Hessian
| get set

Function Hessian (matrix of second derivatives). If CopyReferences=true (false by default) then only the reference is copied in assignments.

Referenced by IG.Num.ScalarFunctionResults.Copy(), and IG.Num.ScalarFunctionUntransformedBase.Evaluate().

bool IG.Num.IScalarFunctionResults.ReqValue
| get set

Indicates whether calculation of function value is/was requested.

Referenced by IG.Num.ScalarFunctionResults.Copy(), and IG.Num.ScalarFunctionUntransformedBase.Evaluate().

bool IG.Num.IScalarFunctionResults.ReqGradient
| get set

Indicates whether calculation of function gradient is/was requested.

Referenced by IG.Num.ScalarFunctionResults.Copy(), and IG.Num.ScalarFunctionUntransformedBase.Evaluate().

bool IG.Num.IScalarFunctionResults.ReqHessian
| get set

Indicates whether calculation of function Hessian is/was requested.

Referenced by IG.Num.ScalarFunctionResults.Copy(), and IG.Num.ScalarFunctionUntransformedBase.Evaluate().

int IG.Num.IScalarFunctionResults.ErrorCode
| get set

Error code. 0 - everything is OK. negative value - something went wrong.

Referenced by IG.Num.ScalarFunctionResults.Copy(), and IG.Num.ScalarFunctionUntransformedBase.Evaluate().

String IG.Num.IScalarFunctionResults.ErrorString
| get set

Error string indicating what went wrong.

Referenced by IG.Num.ScalarFunctionResults.Copy(), and IG.Num.ScalarFunctionUntransformedBase.Evaluate().

bool IG.Num.IScalarFunctionResults.Calculated
| get set

Collectively gets or sets calculated flags. Set false: all calculated flags are set to false. Set true: all calculated flags for which the corresponding request flags are true, are set to truee, others are set to false. Get: returns true if all the flags for which the corresponding request flags are true, are also true. Otherwise returns false.

Referenced by IG.Num.ScalarFunctionUntransformedBase.Evaluate().

bool IG.Num.IScalarFunctionResults.CalculatedValue
| get set

Indicates whether calculation of function value is/was requested.

Referenced by IG.Num.ScalarFunctionResults.Copy(), and IG.Num.ScalarFunctionUntransformedBase.Evaluate().

bool IG.Num.IScalarFunctionResults.CalculatedGradient
| get set

Indicates whether calculation of function gradient is/was requested.

Referenced by IG.Num.ScalarFunctionResults.Copy(), and IG.Num.ScalarFunctionUntransformedBase.Evaluate().

bool IG.Num.IScalarFunctionResults.CalculatedHessian
| get set

Indicates whether calculation of function Hessian is/was requested.

Referenced by IG.Num.ScalarFunctionResults.Copy(), and IG.Num.ScalarFunctionUntransformedBase.Evaluate().

The documentation for this interface was generated from the following file:

- igbase/numeric/FunctionScalarResultsInt.cs