Page 2 of 2 FirstFirst 12
Results 16 to 19 of 19

Math Help - Mathematica Help - Inequalities and Maximization

  1. #16
    Super Member
    Joined
    Aug 2008
    Posts
    903
    Quote Originally Posted by Winding Function View Post
    Shouldn't a*x^2 + b*x + c be in absolute value code?
    Ok, same dif:

    Code:
    In[11]:=
    Maximize[{Abs[a] + Abs[b] + Abs[c], 
       {Abs[a*x^2 + b*x + c] <= 100 && 
         Abs[x] <= 1 && Element[{a, b, c}, 
          Reals]}}, {a, b, c, x}]
    
    During evaluation of In[11]:= Maximize::natt:
    The maximum is not attained at any point satisfying the given \
    constraints.  >>
    
    Out[11]=
    {Infinity, {a -> Indeterminate, 
       b -> Indeterminate, c -> Indeterminate, 
       x -> Indeterminate}}
    For any large value of a, I can find suitable large negative (or positive) values of b and/or c such that Abs[ax^2+bx+c]\leq 100.
    Follow Math Help Forum on Facebook and Google+

  2. #17
    Senior Member bkarpuz's Avatar
    Joined
    Sep 2008
    From
    R
    Posts
    481
    Thanks
    2
    Quote Originally Posted by shawsend View Post
    Ok, same dif:

    Code:
    In[11]:=
    Maximize[{Abs[a] + Abs[b] + Abs[c], 
       {Abs[a*x^2 + b*x + c] <= 100 && 
         Abs[x] <= 1 && Element[{a, b, c}, 
          Reals]}}, {a, b, c, x}]
    
    During evaluation of In[11]:= Maximize::natt:
    The maximum is not attained at any point satisfying the given \
    constraints.  >>
    
    Out[11]=
    {Infinity, {a -> Indeterminate, 
       b -> Indeterminate, c -> Indeterminate, 
       x -> Indeterminate}}
    For any large value of a, I can find suitable large negative (or positive) values of b and/or c such that Abs[ax^2+bx+c]\leq 100.
    So, you agree me?
    Follow Math Help Forum on Facebook and Google+

  3. #18
    Super Member
    Joined
    Aug 2008
    Posts
    903
    Yes. I think we have this one and that's what I'd turn in if it was mine. Of course I thought that with another one in the Calculus forum recently that Opalg schooled me on so I'm more brave then bright.
    Follow Math Help Forum on Facebook and Google+

  4. #19
    Newbie
    Joined
    Oct 2008
    Posts
    12

    Lightbulb

    Okay guys. Firstly, I believe the problem says to maximize |a|+|b|+|c| under the constraint that for all x such that |x|<=1, |ax^2+bx+c|<=100.
    Otherwise, the question really doesnt make too much sense.

    First, I suggest you consider the problem: If |ax^2+bx+c|<=100 is true at the extremes of the domain, it is true in the entire domain. The extremes are at the edges (x= 1), and where x=-b/2a if |-b/2a|<=1. Plugging these values into the restriction, you get |a+b+c|<=100, |a-b+c|<=100, and if |-b/2a|<=1, then |c-b^2/4ac|<=100. Now we plug these into Maximize:
    Maximize[{Abs[a]+Abs+Abs[c],If[Abs[b/(2 a)]1,Abs[c-b^2/(4a)]100,True]&&Abs[a+b+c]100&&Abs[a-b+c]100&&Abs[c]100},{a,b,c}]


    If you are too lazy to think that hard, this method also works, but is much harder for your computer.
    First evaluate:
    Reduce[ForAll[x,Abs[x]1,Abs[ax^2+bx+c]100],{a,b,c}]
    Then evaluate:
    Maximize[{Abs[a]+Abs[b]+Abs[c],%},{a,b,c}]

    Maximize is too weak to expand the original inequality, so plugging it directly into reduce is fruitless. However reduce (the most powerful solving function in mathematica, it gives a completely rigorous expression that takes EVERYTHING into account. If reduce cant do it, mathematica cant do it)
    Reduce gets rid of the ForAll quantifier, and gives back a LONG set of simple inequalities, combined with nested ands and ors. Maximize can deal with that, so you plug it into maximize, and it gives you the answer.

    =)

    Oh, and PS: Element[{a,b,c},Reals] is redundant because maximize by default assumes that the domain is the reals. Furthermore, the third argument of Maximize represents the domain, and using it makes the program faster. The only reason you would use that would be if X were a complex variable. Then it would look something like:
    Maximize[{Expression to be maximized,And@@{List of other constraints}&&Element[{a,b,c},Reals]},{a,b,c,x},Complexes]
    However, in this case x is a quantified real, so it has no buisness being listed as a variable.

    PPS: if the answer were infinity, maximize would give {Infinity, {a ->A-value to make function infinity, b-value -> 0, c-value -> 100}}

    The result is set up so that if you evaluate the following expression immediately after maximize it will return true:
    Equation that you maximized/.%[[2]]==%[[1]]
    Last edited by Hood; October 12th 2008 at 04:30 PM.
    Follow Math Help Forum on Facebook and Google+

Page 2 of 2 FirstFirst 12

Similar Math Help Forum Discussions

  1. Maximization
    Posted in the Calculus Forum
    Replies: 2
    Last Post: May 31st 2010, 02:47 PM
  2. need help with Maximization
    Posted in the Calculus Forum
    Replies: 1
    Last Post: February 26th 2010, 03:46 AM
  3. Inequalities in Mathematica
    Posted in the Math Software Forum
    Replies: 0
    Last Post: November 10th 2009, 12:55 PM
  4. Inequalities [Mathematica]
    Posted in the Math Software Forum
    Replies: 1
    Last Post: October 1st 2008, 02:06 PM
  5. Maximization
    Posted in the Calculus Forum
    Replies: 6
    Last Post: January 19th 2007, 12:39 AM

Search Tags


/mathhelpforum @mathhelpforum