search for: lpsolve

Displaying 20 results from an estimated 78 matches for "lpsolve".

2007 Oct 01
1
lpSolve doesn't compile because of a malloc.h error
Under freebsd 6.2-p7 i386, R 2.5.1,gcc-4.2.2 I'm unable to compile package lpSolve because: hpbsd# R CMD INSTALL lpSolve_5.5.8.tar.gz * Installing to library '/usr/local/lib/R/library' * Installing *source* package 'lpSolve' ... ** libs cc -std=gnu99 -I/usr/local/lib/R/include -I/usr/local/lib/R/include -I . -DINTEGERTIME -DPARSER_LP -DBUILDING_FOR_R -DYY_NEVER_I...
2008 Jan 28
1
Package Installation produces "linux/limits.h: No such file or directory" error when installing the lpSolve package
Dear Friends, I am trying to install a few packages in R and am receiving error messages. Since the error messages are different, I am posting them separately. The second error is with the installation of lpSolve. The core error message is: ======================================================================== In file included from /usr/include/bits/posix1_lim.h:153, from /usr/include/limits.h:145, from /usr/lib64/gcc/x86_64-suse-linux/4.2.1/include/limits.h:122,...
2009 Sep 22
2
Semi continous variable- define bounds using lpsolve
...s a semi continous variable how to define bounds as well as semicontinous function because using set.semicont and set. bound simantaneously doesn't seem to work.Thanks in advance for the help -- View this message in context: http://www.nabble.com/Semi-continous-variable--define-bounds-using-lpsolve-tp25530668p25530668.html Sent from the R help mailing list archive at Nabble.com.
2004 Jun 22
0
semi-continuous variables in lpSolve package
Hi, I am working with lpSolve "R" package by Sam Buttrey, buttrey at nps.navy.mil , which is interface to lp_solve linear/integer programming system. You can find information about lp_solve at http://groups.yahoo.com/group/lp_solve/ (free registration required). lpSolve (R package) supports linear and inte...
2009 Sep 17
0
lpSolve constraints don't seem to have an effect
Dear R users, I would like to optimize a linear approximation of a quadratic function using lpSolve. My code runs without any error or warning message but the constraints that I set don't seem to work properly. Nevertheless, I am certain that my code is somewhere wrong. I would like to solve the following problem: max 2x-x^2+y subject to 2x^2 + 3y^2 <= 6 2>= x,y >= 0 I would spli...
2009 Jul 02
1
lpSolve: how to allow variables to become negative
...ich ARE NOT RESTRICTED TO BE NEGATIVE. In particular, Max {z1,z2,z3,b1} z1 + z2 + z3 (s.t.) # 7 z1 + 0 z2 + 0 z3 + b1 <= 5 # 0 z1 + 8 z2 + 0 z3 - b1 <= 5 # 0 z1 + 0 z2 + 6 z3 + b1 <= 7 # z1, z2, z3 BINARY {0,1} # -5<= b1 <=5 (i.e. b1 <= 5; -b1 <= 5 ) Using the lpSolve package of R, I wrote: library (lpSolve) f.obj <- c(1, 1, 1, 0) f.con <- matrix (c(7, 0, 0, -1, 0, 8, 0, 1, 0, 0, 6, -1, 0, 0, 0, 1 ), nrow=4, byrow=TRUE) f.dir <- c("<=", "<=", "<=", "<=") f.rhs <- c(5, 5, 7, 5) lp ("max"...
2012 Aug 03
0
Binary Quadratic Opt
...> > >> On Wed, Aug 01, 2012 at 04:55:30AM -0700, khris wrote: > >> > Hi Petr, > >> > > >> > It been sometime since I wrote. But here are the latest developments. > >> > > >> > When I give the binary linear opt problem to lpSolve optimizer than for small instance it gives correct answer but when size of nodes increase let's say 16 then there are about 2000 binary variables and lpSolve just does not come back with any answer even after running for a full day. I plan to solve for node size upto atleast 100, so I guess I n...
2010 Jul 06
1
question about lpSolve package
Hello R users, I have two quick questions while using "lpSolve" package for linear programming. (1) the result contains both characters and numbers, e.g., Success: the objective function is 40.5, but I only need the number, can I only store the number? (2) How to set boundaries for variables? e.g., all variable are positive. Thanks a lot! Xiaoxi...
2010 Mar 19
0
lpSolve
Hey, Anyone who knows what the following error report when calling lp() in package lpSolve means? Error: status 3 JT -- View this message in context: http://n4.nabble.com/lpSolve-tp1599380p1599380.html Sent from the R help mailing list archive at Nabble.com.
2007 Mar 09
1
lpSolve space problem in R 2.4.1 on Windows XP
Hi. I am trying to use the linear optimizer from package lpSolve in R 2.4.1 on Windows XP (Version 5.1). The problem I am trying to solve has 2843 variables (2841 integer, 2 continuous) and 8524 constraints, and I have 2 Gb of memory. After I load the input data into R, I have at most 1.5 Gb of memory available. If I start the lp with significantly less m...
2004 Oct 28
0
About lp.assign in lpSolve package
Hi. I've tried to execute &#34;example(lp.assign)&#34; in lpSolve package. However, this solution seemed not to return correct answer, all matrix elements were zeros. Could you give me any &#34;solution&#34; about this? Regards.
2009 Jun 17
0
lpSolve lp const.dir
Hi. In the help page for "lp" in package lpSolve, regarding "const.dir" it says: const.dir: Vector of character strings giving the direction of the constraint: each value should be one of "<," "<=," "=," "==," ">," or ">=". (In each pair the two values are identic...
2010 Jan 28
0
lpSolve API - add Vs set
Hi, Using the package lpSolve API, I need to build a 2000*100000 constraint matrix. I wonder which method is faster: (a) model = make.lp(0,0) add.constraint(model, ...) or (b) model = make.lp(2000,100000) set.constraint(model,...) Thanks ------------ KC
2005 Oct 14
0
arguments of lpSolve
Dear all, I am a beginner with lpSolve package (and not an expert in the others). I can not understand why I am doing wrong, and I would be very grateful if anyone could please help me on this. I am trying to optimize ("min") the sum of columns/variables, constrained to >=1. Each column/variables has its weight - given by...
2013 Apr 23
0
lp.transport in package lpSolve
Dear all, I'm working on a very complex linear optimization problem using the lp.transport function in lpSolve. My PC has 10 cores, but by default R uses only one of them. Is there a straightforward way to make lp.transport use all cores available? I had a look at "High-performance and parallel computing in R" ( http://cran.r-project.org/web/views/HighPerformanceComputing.html), but I have the im...
2005 Oct 14
3
zip package
Dear all I can not understand how to install the package lpsolve_1.1.9.zip I have read the FAQ and the help pages carefully, but it still not clear for me. I have tried the following (and obtained the respective error messages): >install.packages("c:/ProgramFiles/R/rw2011/library/lpSolve_1.1.9",destdir=" c:/ProgramFiles/R/rw2011/library/...
2008 Oct 22
2
suboptimal lp solutions
Hi list, I want to find the total maximum resources I can spend given a set allocation proportion and some simple budget constraints. However, I get suboptimal results via lp and friends (i.e. lpSolve and simplex in the linprog and boot) . For example: library(lpSolve) proportions = c( 0.46, 0.28, 0.26) constraints = c( 352, 75, 171) lp(objective.in = proportions, const.mat = diag(c(1,1,1)), const.rhs=constraints, const.dir=rep('<=',3), direction='max' ) ##...
2007 Mar 05
2
Linear programming with sparse matrix input format?
Hi. I am aware of three different R packages for linear programming: glpk, linprog, lpSolve. From what I can tell, if there are N variables and M constraints, all these solvers require the full NxM constraint matrix. Some linear solvers I know of (not in R) have a sparse matrix input format. Are there any linear solvers in R that have a sparse matrix input format? (including the p...
2005 Mar 30
1
Problems with lpSolve/Memory ? R crashes
Hello! I have a curious problem, which I cannot solve. With my code I solve thousands of small linear programs with the package lpSolve automatically. But R crashes sometimes (~always, but always on different linear programs) in a strange way. For illustration, I tried to prepare a simple example, which shows the nature of the problem. The function aaa (see below) declares some constants (only in this special example) and in the en...
2006 Nov 14
3
lpSolve and mixed signs
Hi R People: If you have a linear programming problem in which some of the constraints have the "<=", some have ">=" and some have "=", all in the same problem, should the solver work? I'm having trouble with that. Any help much appreciated! Sincerely, Erin Hodgess mailto: hodgess at gator.uhd.eud whoops! mailto: hodgess at gator.uhd.edu