示例#1
0
        public SimplexLineCollection(NewObjectiveFunction newObjectiveFunction, List <NewConstrain> newConstrains, OptimisingType type)
        {
            constrains        = newConstrains;
            objectiveFunction = newObjectiveFunction;
            TransponateIfNeeded(type);
            foreach (var item in constrains)
            {
                item.NumberOfConstrains = (constrains.Count);
            }
            int i = 0;

            foreach (var item in constrains)
            {
                item.GenerateSlackVariable(i);
                i++;
            }
            objectiveFunction.GenerateSlackVariable();
        }
示例#2
0
 protected void CreateObjectiveFunctionObject()
 {
     ObjectiveFunction = new NewObjectiveFunction(_ObjectiveFunction, constrainList.Count);
 }