0
$\begingroup$

I have two equations (obtained from differentiating a likelihood function) which I need to solve simultaneously for $c_1$ and $c_2$. The equations are:

$$\sum_i \frac{V(i)}{c_1 + c_2 \xi_i} = n$$

$$\sum_i \frac{V(i)\xi_i}{c_1 +c_2 \xi_i} = \sum_i \xi_i$$

Where $V(i)$ and $\xi_i$ are known quantities. I've tried solving this to no avail, and I'm unsure if it's even possible. If it's not possible, I'll just use a numerical optimization algorithm, but I'd obviously prefer a closed form solution.

So my question is: Is it possible to solve these for $c_1$ and $c_2$, and if so what approach should I take to separate them from these summations?

$\endgroup$
3
  • $\begingroup$ I am afraid that only numerical methods would do the job. I hope and wish for you that $c_1$, $c_2$ and all $\xi_i$ are positive. Is this the case ? $\endgroup$ Aug 9, 2017 at 5:18
  • 2
    $\begingroup$ Depends what you mean by "closed form". If you consider finding a root of a polynomial to be "closed form", then yes it can be done, by first eliminating $c_1$. $\endgroup$ Aug 9, 2017 at 5:24
  • $\begingroup$ @ClaudeLeibovici Yes they are all positive. $V(i)$ is also restricted to being integers. $\endgroup$
    – Patty
    Aug 9, 2017 at 6:03

1 Answer 1

3
$\begingroup$

Let $\xi=\sum_i \xi_i$ and $V = \sum_i V(i)\,$, then multiplying the first equation by $c_1$, the second one by $c_2$, and adding together gives:

$$ \sum_i \frac{c_1V(i)+c_2 V(i)\xi_i}{c_1 + c_2 \xi_i} = c_1 n + c_2 \sum_i \xi_i \;\;\iff\;\; V = c_1 n + c_2 \xi $$

Substituting $\,c_1=(V- c_2 \xi)/n\,$ back into either equation will give a polynomial of degree $N$ to solve for $c_2$ where $N$ is the number of terms in each sum. That's likely to require solving numerically unless there is something particularly "nice" about the combination of $N, V(i), \xi_i$.

$\endgroup$
1
  • 1
    $\begingroup$ I see. Thanks for the solution, unfortunately here $n$ is in the order of millions so that's not very easy. Nonetheless thanks for the quick answer. $\endgroup$
    – Patty
    Aug 9, 2017 at 6:05

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .