Hi All
Apologies if this is not the correct list for this question.
The Rglpk package offers the following example in its documentation
library(Rglpk)
## Simple mixed integer linear program.
## maximize: 3 x_1 + 1 x_2 + 3 x_3
## subject to: -1 x_1 + 2 x_2 + x_3 <= 4
## 4 x_2 - 3 x_3 <= 2
## x
On Thu, Jun 11, 2009 at 9:56 PM, Brecknock, Peter wrote:
> Apologies if this is not the correct list for this question.
>
> The Rglpk package offers the following example in its documentation
>
> library(Rglpk)
> ## Simple mixed integer linear program.
> ## maximize: 3 x_1 + 1 x_2 + 3 x_3
> ## subj
The "1L", etc., forces the number to be integer:
> is.integer(1)
[1] FALSE
> is.integer(1L)
[1] TRUE
Hope this helps.
Spencer
Paul Smith wrote:
On Thu, Jun 11, 2009 at 9:56 PM, Brecknock, Peter wrote:
Apologies if this is not the correct list for this question.
The Rglpk pac
3 matches
Mail list logo