Example #1
0
        public LPForm()
        {
            InitializeComponent();
              var lt1 = new Equation(new Digit[] { new Digit(1), new Digit(-1) }, new Digit(-1));
              //var lt2 = new Equation(new Digit[] { new Digit(-2, 3), new Digit(-1) }, new Digit(7, 2));
              var lt2 = new Equation(new Digit[] { new Digit(-4), new Digit(-6) }, new Digit(21));
              var mainEqua = new Equation(new Digit[] { new Digit(1), new Digit(10) });

              Task task = new Task(Task.TaskType.Max, new Limit[] {
            new Limit(Limit.LimitType.Equal, lt1), new Limit(Limit.LimitType.More, lt2),
              }, mainEqua);
              ss = new SimplexSolver(task);
        }
Example #2
0
        public LPForm()
        {
            InitializeComponent();
            var lt1 = new Equation(new Digit[] { new Digit(1), new Digit(-1) }, new Digit(-1));
            //var lt2 = new Equation(new Digit[] { new Digit(-2, 3), new Digit(-1) }, new Digit(7, 2));
            var lt2      = new Equation(new Digit[] { new Digit(-4), new Digit(-6) }, new Digit(21));
            var mainEqua = new Equation(new Digit[] { new Digit(1), new Digit(10) });

            Task task = new Task(Task.TaskType.Max, new Limit[] {
                new Limit(Limit.LimitType.Equal, lt1), new Limit(Limit.LimitType.More, lt2),
            }, mainEqua);

            ss = new SimplexSolver(task);
        }