Optimisation mit constraint

*To*: mathgroup at yoda.physics.unc.edu*Subject*: Optimisation mit constraint*From*: Colin Rose <colinr at extro.ucc.su.oz.au>*Date*: Tue, 24 Nov 92 3:55:21 EST

Rod Price writes: >> I need to minimize a function of about thirty variables subject to >> three constraint equations, each of which involves all thirty >> variables. If I didn't have the constraints, I would use something >> like FindMinimum[] to do the minimization numerically. On the other >> hand, if I had only a few variables, I would use Lagrange multipliers >> to solve the minimization problem by hand. Unfortunately, I can't do >> either, so: Is there a way of minimizing my function numerically in >> Mma with the constraints? If your function is linear (and if your constraints are linear), you can use ConstrainedMin[]. If it is NOT linear, may I suggest: 1. Specify the Lagrangean in Mma: call it L. Then... 2. NSolve[ { D[L, x1] == 0, D[L, x2] == 0, etc D[L, lambda1] == 0, etc }, {x1, x2, ..., x30, lambda1, lambda2, lambda3} ] which may do it for you. Of course, if you have 30 variables, this may prove somewhat tedious. If my memory serves me correctly, Hal Varian has a package that automates much of the tedium in this respect in his book... Varian, Hal (1992), Economic and Finanical Modeling with Mma.... It should be out before the year's end. Regards Colin Colin Rose Dept. of Economics University of Sydney colinr at extro.ucc.su.oz.au *************************