Public Member Functions | |
LeafNode (StageNode *ptPred, const int nodeN, const double condProb, const double *ptRetVect, const double capTarget) | |
Constructs a LeafNode object. | |
Public Attributes | |
MP_variable | w |
shortage variable | |
MP_variable | y |
surplus variable | |
MP_constraint | finalBalance |
constraint for the final balance | |
MP_data | Return |
returns of the assets at this node | |
Protected Member Functions | |
void | make_obj_function_ () |
version of make_obj_function_() for the leaves - no recursion |
Definition at line 121 of file investment.cpp.
LeafNode::LeafNode | ( | StageNode * | ptPred, | |
const int | nodeN, | |||
const double | condProb, | |||
const double * | ptRetVect, | |||
const double | capTarget | |||
) | [inline] |
Constructs a LeafNode object.
In this case, we use a deep copy for the MP_data
Return, i.e. the return values in the constraints are copied from the retVect array to the constraints. This means that the retVect array can be safely changed or deleted afterwards.
Definition at line 133 of file investment.cpp.
References StageNode::ASSETS, finalBalance, StageNode::ptParent, Return, w, StageNode::x, and y.
void LeafNode::make_obj_function_ | ( | ) | [inline, protected, virtual] |
version of make_obj_function_() for the leaves - no recursion
Reimplemented from StageNode.
Definition at line 145 of file investment.cpp.
References StageNode::objFunction, StageNode::prob, w, and y.
MP_variable LeafNode::w |
shortage variable
Definition at line 123 of file investment.cpp.
Referenced by LeafNode(), and make_obj_function_().
MP_variable LeafNode::y |
surplus variable
Definition at line 124 of file investment.cpp.
Referenced by LeafNode(), and make_obj_function_().
MP_constraint LeafNode::finalBalance |
constraint for the final balance
Definition at line 125 of file investment.cpp.
Referenced by LeafNode().
MP_data LeafNode::Return |
returns of the assets at this node
Definition at line 126 of file investment.cpp.
Referenced by LeafNode().