44 questions
0
votes
0
answers
73
views
Cycling of Lexicographic simplex method
I am studying the cycling of simplex method. I know that there is a lexicographic rule to prevent looping of the simplex method, and I also know that this rule should be applied to a lexicographically ...
0
votes
0
answers
64
views
Libreoffice Solver to java implementation with apache-commons-math
Trying to implement and solve a Linear Programming problem with in Java using apache-commons-math:
<dependency>
<groupId>org.apache.commons</groupId>
<...
5
votes
2
answers
564
views
linear programming in R | limits to what it can do, or my mistake?
Question for 'experts' in LP using R (using the lpSolve package, say) -- which does not apply to me for the sort of problem I describe below.
I've run any number of LP's using lpSolve in R, but all of ...
1
vote
1
answer
1k
views
Solve a linear programming (LP) problem in R
The function takes in the coefficients of the objective function, the constraints matrix, the right-hand side values for the constraints, the direction of the constraints, and the type of the LP ...
0
votes
1
answer
91
views
compute the tableau's nonbasic term in SCIP separator
In traditional Simplex Algorithm notation, we have x at the current basis selection B as so:
xB = AB-1b - AB-1ANxN. How can I compute the AB-1AN term inside a separator in SCIP, or at least iterate ...
0
votes
1
answer
72
views
custom cutter has invalid Lhs or Rhs
I'm trying to write a custom separator (aka, MIP cutter) to my SCIP model (in Python). To do this I need to detect which constraints are tight/binding at the given MIP node. I thought that I could do ...
-1
votes
1
answer
78
views
How can I order the basic solutions of a min cost flow problem according to their cost?
I was wondering if, given a min cost flow problem and an integer n, there is an efficient algorithm/package or mathematical method, to obtain the set of the
n-best basic solutions of the min cost flow ...
0
votes
0
answers
599
views
Example for SimplexSolver in Apache Commons Maths 3.6.1
I am new to linear optimization and currently trying to use the SimplexSolver.class from org.apache.commons.math3.optim.linear.
So I looked up some examples on how to use it, to understand it and also ...
1
vote
2
answers
463
views
2D fiber alignment using the simplex algorithm
I have been writing some code for automatically aligning my fiber (whose X, Y, Z positions are controlled by a motor) to a light source. For this I have written my axis.move_to(pos) method to move an ...
1
vote
0
answers
394
views
python network simplex algorithm for transportation problem?
After doing a lot of research I'm unable to find a network simplex algorithm for Python. This algorithm has been implemented in many other languages so there must be a python implementation I guess?
I ...
0
votes
1
answer
748
views
python networkX network simplex
I'm trying to solve a transportation problem using the networkX library.
As my demand and supply values are floats my problem seems to be unsolvable by the networkX package?
see documentation on Page ...
0
votes
1
answer
1k
views
Revised simplex method enters endless loop
I'm trying to implement a revised simplex method (RSM) algorithm using Python and numpy. I'm stuck with its either working on maximization only (correct on tiny matrices like 2x4, 5x5 etc and wrong on ...
0
votes
1
answer
163
views
How to create a simplex algorithm table
I am trying to create a table that can have user input. I want to have a table with boxes instead of asking the user for a list of numbers, they can just input a lot of numbers into the table. Right ...
0
votes
1
answer
253
views
How to write Simplex method (in tableau/matrix form) from scratch in python?
I have got my equations and everything set. I just don't know how to iterate, i.e. how to update A, b and c. I have been trying with the matrix form. If anybody could help with that or the tableau ...
0
votes
1
answer
178
views
Dual values of optimal bases
Suppose that we have a linear program (LP) that has at least two optimal bases B1 and B2. Are the dual values associated with B1 equal the dual values associated with B2? In other words, can we ...
2
votes
1
answer
342
views
linear optimization with scipy / simplex do not deliver optimum
I am trying to solve the problem described by Saul Grass in his book "Illustrated Guide to Linear Programming", page 12ff The transportation problem.
Refrigerators have to be delivered to 3 ...
2
votes
1
answer
442
views
Solve optimization with binary variables
I'm trying to optimize the following: people (column id) should go to one of the points A:G. Let's say that exactly two people (from a group of 14) must go to one of the 7 locations. I want to ...
0
votes
4
answers
3k
views
Optimization: Farming wheat and rice
This is the problem statement
An Indian farmer has a piece of farmland, say L square kilometers long, and wants to either sow wheat or rice or a combination of both. The farmer has a limited amount of ...
2
votes
0
answers
1k
views
How do you estimate the parameter error/uncertainties using the Nelder-Mead method in scipy.optimize.minimize using the final_simplex in the output
I am trying to estimate the error/uncertainties in the estimation of the power-law fitting parameters (m, n, b) of the form y = m(x-b)^n, which I fitted to a dataset. When I use the Nelder-Mead method ...
0
votes
1
answer
88
views
linear programming explanation in algorithms by Sanjoy Dasgupta
I am reading simplex algorithm in text book titled Algorithms by Dasgupta-Papadimitriou-Vairani
On each iteration, simplex has two tasks:
1. Check whether the current vertex is optimal (and if so, ...
1
vote
1
answer
1k
views
Simplex Algorithm: Initialize-Simplex
I am trying to figure out the simplex algorithm in the book "Introduction to Algorithms, 3rd edition". The procedure "Initial-Simplex" takes as input a standard form, and check if there is an initial ...
0
votes
0
answers
225
views
Having negative value for non basic variable gives a non feasible solution in simplex method?
Objective function => x1 - 2x2
Subject to =>
x2 <= 5
x1 - x2 >= 2
x1 ,x2, x3 >= 0
Maximize?
convert to standard form :
Maximize -> -x1 + 2x2
Subject to ->
x2 <= 5
-x1 + ...
1
vote
1
answer
1k
views
Implementing Simplex Method infinite loop
I am trying to implement a simplex algorithm following the rules I was given at my optimization course. The problem is
min c'*x s.t.
Ax = b
x >= 0
All vectors are assumes to be columns, ...
0
votes
0
answers
1k
views
Big Datasets for Simplex Algorithm (Linear Programming)
I need Big Datasets to test a parallel version of the simplex algorithm i am writing. The only Datasets i can find are in a Format called MPS but i cannot find a parser for MPS in Python or C.
I ...
0
votes
0
answers
160
views
Pivoting in simplex method for solving linear programming
A common linear programming problem below
min c'x
s.t. Ax<=b
(A is m*n, m is smaller than n)
As I know, the pivoting procedure in simplex method lets extreme point jump to another extreme point ...
0
votes
1
answer
126
views
Apache commons SimplexSolver: OutOfMemoryError
I have a problem with 841 variables and 23382 constraints (not particularly large for LP).
Nevertheless, i get an OutOfMemoryError when using the Apache SimplexSolver, even for a heap size of 1GB.
...
1
vote
1
answer
1k
views
Linear programming with scipy.optimize.linprog returns Optimization failed
I am trying to use linprog in order to optimise the following problem (uploaded in Google Drive). The dataset itself is uploaded here
So far I have the written the following implementation in Python:
...
1
vote
1
answer
866
views
Solving LPP using Simplex Method with variables subject to a range
I am currently working on a problem which can be solved using linear programming according to the research I have done here, on YouTube and on other websites. I have familiarized myself with the so ...
1
vote
0
answers
2k
views
Simplex algorithm in Excel without Solver
I am looking for an Excel table with formulas (no VBA, no Solver) that can solve LP problems:
Ax=b
0<=x
cx->min
With Solver and VBA, I can do it but I would like a solution which builds only on ...
0
votes
1
answer
826
views
Issues with Simplex method for linear programming in Matlab (linprog funcion)
I am using the linprog function in Matlab to solve a set of large linear programming problems. I have 2601 decision variables, 51 inequality constraints, 71 equality constraints, and lower bounds of 0 ...
0
votes
1
answer
371
views
Creating BlockMatrix of m rows n columns where m is not equal to n without using 'transpose'
I am working on an algorithm which has the following things
A = np.array([[10, 5, 1, 0, 0],
[6, 6, 0, 1, 0],
[4.5, 18,0, 0, 1]])
nonbasis = np.array([0, 1])
basis = np.array(...
1
vote
1
answer
135
views
Pulling non zero values from excel
i have made this table in excel of items of food from a menu with their nutritional value. I've then got another table that has each item in one row and the quantity consumed of each item In the row ...
0
votes
1
answer
153
views
get target vector from simplex optimisation in R
I started using R to solve a LP-Problem using the simplex funciton from library("boot"). When i try the following code I only get the target vector as string but not as a vector.
library("boot")
# ...
0
votes
2
answers
955
views
Methods of testing Simplex (Linear Programming) calculation output
I have been tasked with created a web-based machine for solving real-world issues using Linear Programming techniques, specifically at present, Danzig's Simplex Method. With this in mind I've found a ...
0
votes
1
answer
102
views
Optimsimplex: fail in defining a necessary argument
I was trying to do a regular simplex (the notion of a triangle or tetrahedron to arbitrary dimensions) to start an optimization set of experiments. The Optimsimplex package provides an easy and useful ...
1
vote
1
answer
2k
views
linear programming with dual simplex in R
I have a linear programming problem that I'm trying to solve in R. I have used lpSolve package. lpSolve by default uses primal simplex algorithm to obtain solution. What if I want to change the ...
1
vote
1
answer
6k
views
A basic example of the simplex function in R with errors
Good morning,
I have a question to an optimization problem I can't solve in R but in Excel:
I would like to optimize the following situation (Transportation of material and people):
Airline x1 can ...
0
votes
1
answer
2k
views
simplex method with bounded variables tool
Is there any reliable tool or source code (preferably C++) for solving LPs with bounded variables by simplex method? In my problem all variables are bounded to 1.
I actually found some tools in ...
1
vote
1
answer
669
views
OpenSimplexNoise higher detail level
I'm new to world generation and the algorithms which are used for them, so I hope someone can give me some usefull explanation or code or both or links to some resources I missed while searching for a ...
-1
votes
1
answer
149
views
solver gets the minimum value set in decision
I am running a code that needs to calculate the appropriate percentage of ingredients to compose an animal food. In order to do it I am using MS solver foundation. I set the model passing the minimum ...
0
votes
0
answers
132
views
Matlab invalid vector using lpsolve
I am using a function in Matlab based on lp_solve. In my case, lp_solve is structured as follows:
A = rand (13336,3); %A is made of real numbers between 0 and 1. For this mwe, I thought 'rand' was ...
2
votes
0
answers
1k
views
Nelder-Mead initial simplex size
I use Matlab's fminsearch function for finding the minimum with Nelder-Mead. fminsearch calculates the size of the initial simplex automatically. In my case, the initial simplex is too small, thus it ...
2
votes
0
answers
445
views
How to handle the special cases of simplex algorithm for linear programming
This is a follow-up question to the SO question: Code a linear programming exercise by hand . I have a similar interest in implementing the simplex algorithm (linear programming) for pedagogical ...
0
votes
2
answers
7k
views
Minimize Simplex method
I find topic about Simplex method here Alter Simplex Algorithm to Minimize on objective function NOT maximize
But answer didn`t help. When I change from
double[] variables = { 13.0, 23.0 };
to
...