[R] Non linear programming optimization (which package to use?)

Jerome Chong jeromechong at gmail.com
Thu Nov 12 17:53:10 CET 2009


>
> Hello,
>
> 1) Is there any nonlinear programming optmizer that I can user for the
> following problem?
>
> Obj function: (max) revenue = price * volume
> Constraints: price and volume pair must be from the following variable data
set:
>
> Variable data set:
> # price volume
> 1 10 500
> 2 20 450
> 3 30 330
> 4 40 250
> 5 50 190
>
> Expected result: 10,000 (variable row#4)
>
> 2) Could it also be possible for the suggested non-linear programming
> optimizer to accept formula (done with regression) and use it for
> optimization purpose? If so, how?
> Example:
> Fitted to: revenue = -700price^2 + 5200price + 780
> Subject to: price range between 10 to 50
>
> Thanks,
> Jerome
>
>


You are confused. That is not an nonlinear programming problem. You can just
run through the data set and pick the largest product.

Erwin

----------------------------------------------------------------
Erwin Kalvelagen
Amsterdam Optimization Modeling Group
erwin at amsterdamoptimization.com
http://amsterdamoptimization.com

Greetings,

What I want to do is to perform regression the data set to get a
revenue function, and use that revenue function to find the maximum
point (maybe with some constraints applied).
The regressed revenue function would most likely be in a quadratic
form (depending on the price-volume data set), and the constraints
most likely will be in linear form.
If I just get the largest product from the data set, it might not give
me the maximum revenue from the revenue function (assuming not
violating any constraints).
To take the constraints into account, won't I be needing non-linear programming?

And if I expect the variable to be an integer value (say price for
maximized revenue needs to be in integer), I would be requiring mixed
integer programming.

Is there a single package can I use to handle all these?

/Jerome




More information about the R-help mailing list