a101e99aad
BLayout implementation (BALMLayout) using the Auckland Layout Model (ALM). The original ALM was implemented by Christof Lutteroth, the Haiku/C++ version by James Kim. The code needs some review, but the test programs seem to work fine. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@23889 a95241bf-73f2-0310-859d-f6bbb57e9c96
40 lines
658 B
C++
40 lines
658 B
C++
#ifndef OBJ_FUNCTION_SUMMAND_H
|
|
#define OBJ_FUNCTION_SUMMAND_H
|
|
|
|
|
|
namespace LinearProgramming {
|
|
|
|
class LinearSpec;
|
|
class Variable;
|
|
|
|
/**
|
|
* A summand of the objective function.
|
|
*/
|
|
class ObjFunctionSummand {
|
|
|
|
public:
|
|
double Coeff();
|
|
void SetCoeff(double coeff);
|
|
Variable* Var();
|
|
void SetVar(Variable* var);
|
|
~ObjFunctionSummand();
|
|
|
|
protected:
|
|
ObjFunctionSummand(LinearSpec* ls, double coeff, Variable* var);
|
|
|
|
private:
|
|
LinearSpec* fLS;
|
|
double fCoeff;
|
|
Variable* fVar;
|
|
|
|
public:
|
|
friend class LinearSpec;
|
|
|
|
};
|
|
|
|
} // namespace LinearProgramming
|
|
|
|
using LinearProgramming::ObjFunctionSummand;
|
|
|
|
#endif // OBJ_FUNCTION_SUMMAND_H
|