MathGroup Archive 2001

[Date Index] [Thread Index] [Author Index]

Search the Archive

RE: Optimal Method

  • To: mathgroup at smc.vnet.net
  • Subject: [mg28656] RE: [mg28638] Optimal Method
  • From: "Higinio Ramos" <higra at gugu.usal.es>
  • Date: Sat, 5 May 2001 04:00:41 -0400 (EDT)
  • References: <200105030828.EAA20526@smc.vnet.net>
  • Sender: owner-wri-mathgroup at wolfram.com

----- Original Message -----
From: Shengli Fu <sfu at cs.wright.edu>
To: mathgroup at smc.vnet.net
Subject: [mg28656] [mg28638] Optimal Method


> My problem is: find x to maximum sum[(x(i)+a(i))log(x(i))], in which a(i)
> is constant. i is from 1 to 3.
>
> There is one constraint: 0<x(i)<1, sum(x(i)) = 1.
>
> Any one can give me a hint on this question.
>
> Thanks in advance.
>
By classical method:
Let the objective function expressed in terms of x,y,z instead of x(i) :
f[x_,y_,z_].=x +a1 Log[x] + y + a2 Log[y] + z +a3  Log[z].
As there is the constraint x+y+z=1, this led to express f as a function of
two variables,
f[x_,y_]:=x + a1 Log[x] + y + a2 Log[y] + 1 - (x + y) + a3 Log[1 - (x + y)]
Then deriving with respect to x and y and solving the system
D[f,x]==0,D[f,y]==0 we obtain the critical points among then we obtain the
maximum with the constraints 0<x,y,z<1 if exists.

Using Mathematica functions:
maximum[a1_, a2_, a3_] :=
  FindMinimum[-(x + 1Log[x] + y + 2 Log[y] + 1 - (x + y) +
          3 Log[1 - (x + y)]), {x, {0.001, 1}}, {y, {0.001,
        1}}] /. {h_, {p__}} -> ({f -> -h, {p,
          z -> (Evaluate[1 - (x + y) /. {p}])}})
Notice that the minimum of f is the maximun of -f, so we have to change the
sign of the result.



  • Prev by Date: Re: Simple indefinite integral disagrees with table
  • Next by Date: ScatterPlot3D/Plot3D
  • Previous by thread: Optimal Method
  • Next by thread: Looking for variational calculus tutorials