Results 1 to 4 of 4

Math Help - Program/method to find the maxima of a large (yet simple) equation

  1. #1
    Newbie
    Joined
    Apr 2011
    Posts
    21

    Program/method to find the maxima of a large (yet simple) equation

    I have an equation that looks like:

    \frac{x m_1 + (1-x) m_2}{\sqrt{x^2 v_1 +(1-x)^2 v_2 + 2x(1-x)c}}

    where m1 and m2 are means, v1 and v2 are variances and c is the covariance(m1, m2).

    My objective is to find the absolute maxima of this equation.

    This can be easily solved by taking the first derivative, set the equation to zero and solving for x.

    Now, suppose that I have N of that equation, where the i index refers to the index of the ith equation, i.e., i = 1,...N.

    My objective would be to find the maxima of the following equation:


    \sum_{i = 1}^N \omega_i\frac{x m_1_i + (1-x) m_2_i}{\sqrt{x^2 v_1_i +(1-x)^2 v_2_i + 2x(1-x)c_i}}


    where W_i is the weight in the running sum of the ith equation. Note that I have all values W_i, m1_i, m2_i, var1_i, var2_i and c_i. I need to find the value of x that maximizes the above mentioned sum.

    I can easily solve this numerically, but I believe there is a smarter way. Since my background is in Biomedical Sciences, I would be really grateful for any help from math experts. There is any program/algorithm that I might use, for example?

    Cheers!

    Alonso

    P.S. I can easily solve that problem numerically, because I now the value of x will be constrained on the interval [-5,+5]
    Last edited by Alonso; May 27th 2011 at 01:46 PM.
    Follow Math Help Forum on Facebook and Google+

  2. #2
    Member
    Joined
    May 2011
    From
    Sacramento, CA
    Posts
    165
    It might be helpful to see the equation in Latex. Is the following correct?

    \frac{x m_1 + (1-x) m_2}{\sqrt{x^2 var_1 +(1-x)^2 var_2 + 2x(1-x)c}}

    This can be reproduced by the following latex statement (for future reference):

    [tex]\frac{x m_1 + (1-x) m_2}{\sqrt{x^2 var_1 +(1-x)^2 var_2 + 2x(1-x)c}}[/tex]
    Follow Math Help Forum on Facebook and Google+

  3. #3
    Newbie
    Joined
    Apr 2011
    Posts
    21
    Hi, Bryan. Thank you very much for the example. I could not use latex, because I could not understant it here. With you example, I could figure it out. Thanks!
    Follow Math Help Forum on Facebook and Google+

  4. #4
    Member
    Joined
    May 2011
    From
    Sacramento, CA
    Posts
    165
    There's a forum around here somewhere that is dedicated to Latex question. If you keep talking math, you have to learn it! There's also plenty of online resources to look up examples and codes for what you want to express. Good job on converting your first post to latex.
    Follow Math Help Forum on Facebook and Google+

Similar Math Help Forum Discussions

  1. Program for Jacobi iterative method using Matlab.
    Posted in the Advanced Math Topics Forum
    Replies: 2
    Last Post: November 17th 2010, 01:00 AM
  2. Replies: 1
    Last Post: October 13th 2010, 05:18 PM
  3. Simple Math Program
    Posted in the Math Topics Forum
    Replies: 2
    Last Post: November 4th 2009, 07:17 PM
  4. Help with Simple Probability Program
    Posted in the Statistics Forum
    Replies: 2
    Last Post: March 12th 2008, 09:37 PM
  5. Replies: 4
    Last Post: August 26th 2005, 09:01 PM

Search Tags


/mathhelpforum @mathhelpforum