MathGroup Archive 2010

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

Search the Archive

Re: Equation solving question

  • To: mathgroup at smc.vnet.net
  • Subject: [mg111721] Re: Equation solving question
  • From: "Sjoerd C. de Vries" <sjoerd.c.devries at gmail.com>
  • Date: Wed, 11 Aug 2010 04:48:05 -0400 (EDT)
  • References: <i3r0lt$dfb$1@smc.vnet.net>

Couldn't solve your system, but AFAIK Solve doesn't accept
Assumptions, so setting up an Assuming environment for Solve won't
work. You should resort to Reduce which can solve systems of
equalities and inequalities (but doesn't yield a quick solution either
in this case).

Cheers -- Sjoerd

On Aug 10, 9:55 am, Yaroslav Bulatov <yarosla... at gmail.com> wrote:
> I'd like to solve the system of equations below and Mathematica gets
> stuck, are the tricks I can do to help it solve this kind of system?
> It should produce solution q1=p1, q2=p2, q3=p3, q4=p4
>
> lagr = p1 (Log[q1/(q1 + q3)] + Log[q1/(q1 + q2)]) +
>    p2 (Log[q2/(q1 + q2)] + Log[q2/(q2 + q4)]) +
>    p3 (Log[q3/(q1 + q3)] + Log[q3/(q3 + q4)]) +
>    p4 (Log[q4/(q2 + q4)] + Log[q4/(q3 + q4)]) - \[Lambda] (q1 + q2 +
>       q3 + q4 - 1);
> vars = {q1, q2, q3, q4, \[Lambda]};
>
> Assuming[{p1 > 0 && p2 > 0 && p3 > 0 && p4 > 0 &&
>    p1 + p2 + p3 + p4 == 1 && q1 > 0 && q2 > 0 && q3 > 0 && q4 > 0=
},
>  Solve[D[lagr, #] == 0 & /@ vars, vars]]
>
> Motivation: I'm trying to show consistency of some pseudo-likelihood
> estimators, this example is the simplest case where PL applies



  • Prev by Date: Run a package from the command line without launching a notebook?
  • Next by Date: Re: A new graphic user interface
  • Previous by thread: Equation solving question
  • Next by thread: Re: Equation solving question