# Finding the maximum value of the function with many variables and theirs limitations

• Oct 14th 2011, 12:12 AM
randomLEMPL
Finding the maximum value of the function with many variables and limitations
Hello,

is there any software, which can calculate what is the maximum value of a particular function with, approximately, 10 variables, when all of these variables are limited [e.g., x is an integer from (150;650); y accords to a rational number from (1;2); etc.)?

I have been told that MS Office Excel's Solver should be able to do that, but I haven't found a way how to do that and finally, someone has mentioned that it is not possible in Solver, because it counts numerically and moves from one point to another as long as it finds a local maximum.
• Oct 14th 2011, 10:35 PM
CaptainBlack
Re: Finding the maximum value of the function with many variables and limitations
Quote:

Originally Posted by randomLEMPL
Hello,

is there any software, which can calculate what is the maximum value of a particular function with, approximately, 10 variables, when all of these variables are limited [e.g., x is an integer from (150;650); y accords to a rational number from (1;2); etc.)?

I have been told that MS Office Excel's Solver should be able to do that, but I haven't found a way how to do that and finally, someone has mentioned that it is not possible in Solver, because it counts numerically and moves from one point to another as long as it finds a local maximum.

Without special conditions most software cannot guarantee that it will find a global extremum of a function. Excel is a good bet since you seem to have a mixed integer problem here (you can ignore the rationality constraints they are irrelevant since floating point is a subset of rationals), but there is no guarantee that it will work, you will have to experiment a bit with changing the initial point and see how that effects the result.

For alternatives see Global optimization - Wikipedia, the free encyclopedia

Personally I like variants of stochastic search (posh name for Monte-Carlo based methods)

It would be nice if you could post the full problem statement here.

CB
• Oct 15th 2011, 06:13 AM
randomLEMPL
Re: Finding the maximum value of the function with many variables and limitations
Quote:

Originally Posted by CaptainBlack
Without special conditions most software cannot guarantee that it will find a global extremum of a function. Excel is a good bet since you seem to have a mixed integer problem here (you can ignore the rationality constraints they are irrelevant since floating point is a subset of rationals), but there is no guarantee that it will work, you will have to experiment a bit with changing the initial point and see how that effects the result.

For alternatives see Global optimization - Wikipedia, the free encyclopedia

Personally I like variants of stochastic search (posh name for Monte-Carlo based methods)

It would be nice if you could post the full problem statement here.

CB

Will it help if I don't insist on integers?

It is a dummy profit function (from a certain game), which is covering all variables - labor, inputs,... (some of these variables are part of revenue as well as expense part) - and I want to find its maxima, i.e. the highest possible profit (I do determine the quantity).
Actually, it doesn't have to be maxima since it is that much hard to reach - something near the maxima would be definitely nice, too, considering the problem's difficulty.

Any idea what software and how should I use for that? Matlab, Maple or straight global optimization sw (LIONsolver 2.0,...)? Thanks!
• Oct 15th 2011, 06:21 AM
CaptainBlack
Re: Finding the maximum value of the function with many variables and limitations
Quote:

Originally Posted by randomLEMPL
Will it help if I don't insist on integers?

It is a dummy profit function (from a certain game), which is covering all variables - labor, inputs,... (some of these variables are part of revenue as well as expense part) - and I want to find its maxima, i.e. the highest possible profit (I do determine the quantity).
Actually, it doesn't have to be maxima since it is that much hard to reach - something near the maxima would be definitely nice, too, considering the problem's difficulty.

Any idea what software and how should I use for that? Matlab? Maple? Thanks!

Matlab has tools that should be capable of doing the job, I know Maple less well than Matlab but I believe it also could do this.

I can't tell you how to use the tools in these packages since I do not use them for such tasks, you will have to look at the documentation, and other support (there is a vast amount of Matlab software available from Matlab central)

CB