Take the 2-minute tour ×
Mathematica Stack Exchange is a question and answer site for users of Mathematica. It's 100% free, no registration required.

How I can solve these five non-liner equations

where n=3, x=1,3,8 (e.g), and a,b,c, Alpha and Beta should be estimated.

x = {1, 3, 8}; n = Length[x]; eqn1 = n*D[Beta[a, b], a]/Beta[a, b] - 
alpha*c*Sum[x[[i]]^(-beta), {i, 1, n}] == 0;  eqn2 = Sum[Log[1 - Exp[-alpha*c*x[[i]]^(-beta)]], {i, 1, n}] - n*D[Beta[a, b], b]/Beta[a, b] == 0; eqn3 = n/c - alpha*a*Sum[x[[i]]^(-beta), {i, 1, n}] + alpha*(b - 1)*Sum[(x[[i]]^(-beta)*Exp[alpha*c*x[[i]]^(-beta)])/(1 - Exp[-alpha*c*x[[i]]^(-beta)]), {i, 1, n}] == 0; eqn4 = n/alpha - c*a*Sum[x[[i]]^(-beta), {i, 1, n}] + c*(b - 1)*Sum[(x[[i]]^(-beta)*Exp[-alpha*c*x[[i]]^(-beta)])/(1 - Exp[-alpha*c*x[[i]]^(-beta)]), {i, 1, n}] == 0; eqn5 = n/beta - Sum[Log[x[[i]]], {i, 1, n}] + alpha*a*c*Sum[Log[x]*x[[i]]^(-beta), {i, 1, n}] + alpha*beta*c*(b - 1)*Sum[(x[[i]]^(-beta)*Exp[-alpha*c*x[[i]]^(-beta)])/(1 - Exp[-alpha*c*x[[i]]^(-beta)]), {i, 1, n}] == 0; FindRoot[{eqn1, eqn2, eqn3, eqn4, eqn5}, {{a, 0.1}, {b, 0.1}, {c, 0.1}, {alpha, 0.1}, {beta, 0.1}}]

This is not working, and not sure {a,0.1} etc 0.1 is the initial value.

share|improve this question
    
Is this a Mathematica question or is it more about mathematics? What have you tried so far? You should at least demonstrate that you already put some effort into solving the Problem. It helps to give some working code snippets, others can built upon. –  Markus Roellig Jun 21 '13 at 11:05
    
actually i am new in Mathematica, but i am sure there is must a method to handle this problem. –  Azeem Jun 21 '13 at 11:18
    
Then a good starting point would be: mathematica.stackexchange.com/questions/18/… –  Sektor Jun 21 '13 at 11:25
    
Nikola: I just want what should be the basic function to solve this problem. –  Azeem Jun 21 '13 at 11:38
1  
@Emy Solve can't solve that system :) But, generally speaking, yes that's what you will use Azeem when you need to solve a system of equations :) –  Sektor Jun 21 '13 at 11:47
show 23 more comments

1 Answer

up vote 3 down vote accepted

With the help of the formulae that you posted, I came up with:

x = {1, 3, 8};
n = Length[x];

eqns = Simplify[
{
  n D[Beta[a, b], a]/Beta[a, b] + alpha c Sum[x[[i]]^(-beta), {i, 1, n}],
  Sum[Log[1 - Exp[-alpha c x[[i]]^(-beta)]], {i, 1, n}] - n D[Beta[a, b], b]/Beta[a, b],
n/c - alpha a Sum[x[[i]]^(-beta), {i, 1, n}] + alpha (b - 1) Sum[(
    x[[i]]^(-beta) Exp[-alpha c x[[i]]^(-beta)])/(
    1 - Exp[-alpha c x[[i]]^(-beta)]), {i, 1, n}],
n/alpha - alpha c Sum[x[[i]]^(-beta), {i, 1, n}] + 
c (b - 1) Sum[(x[[i]]^(-beta) Exp[-alpha c x[[i]]^(-beta)])/(
    1 - Exp[-alpha c x[[i]]^(-beta)]), {i, 1, n}],
n/beta - Sum[ Log[x[[i]]], {i, 1, n}] + 
  alpha a c Sum[x[[i]]^(-beta), {i, 1, n}] + 
  alpha beta c (b - 1)  Sum[(
    x[[i]]^(-beta - 1) Exp[-alpha c x[[i]]^(-beta)])/(
    1 - Exp[-alpha c x[[i]]^(-beta)]), {i, 1, n}]
}
];


soln=FindRoot[
 eqns
 , {{a, 0.1}, {b, 0.1}, {c, 0.1}, {alpha, 0.1}, {beta, 0.1}}]

which returns

 {a -> 0.74093, b -> 0.571156, c -> 3.38077, alpha -> 0.74093, 
  beta -> 1.90692}

Then you can verify the solution:

 eqns /. soln

which should return a list with five "essentially zeros".

  {9.47241*10^-7,-0.0000120965,-2.58065*10^-7,-1.17752*10^-6,-1.86303*10^-6}

(If you omit the "==0" parts of the definition of the equations (eqns), Mathematica will assume that you mean "==0" for purposes of FindRoot. )

share|improve this answer
    
...and if someone could point me in a direction that gives advice on how to format these monster-sized expressions... –  Eric Brown Jun 21 '13 at 16:43
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.