MathGroup Archive 2008

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

Search the Archive

Re: Maximize command - trigonometric function

  • To: mathgroup at smc.vnet.net
  • Subject: [mg85090] Re: [mg85072] Maximize command - trigonometric function
  • From: bsyehuda at gmail.com
  • Date: Mon, 28 Jan 2008 03:25:44 -0500 (EST)
  • References: <200801271043.FAA15369@smc.vnet.net>

Even without a computer with Mathematica I can see that you need to change
parenteses to square brackets, that is Cos[t1] etc.
Mathematica takes your input and Cos(t1) is interpreted as Times[Cos,t1] and
do it seven times makes the Cos^7 error together with t1 t2 t3 t4 t5 t6 t7

So, first make this change

best
yehuda


On 1/27/08, Crazy Man <geller_gambit at hotmail.com> wrote:
>
> Hi all.
>
> I am trying to use Maximize function to find the maximum of a
> trigonometric function of 7 variables. But it¢¥s not working. I will show
> what I am doing.
>
> First I define
>
> B = (2*1*Cos(t1)*Cos(t2)*Cos(t3)*Cos(t4)*Cos(t5)*Cos(t6)*Cos(t7));
>
> Then I try
>
> Maximize[{B, -¥ð/2
> ¡Â t1 ¡Â ¥ð/2 && -¥ð/2 ¡Â t2 ¡Â ¥ð/2 && -¥ð/2 ¡Â t3 ¡Â
>      ¥ð/2 && -¥ð/2 ¡Â t4 ¡Â ¥ð/2 && -¥ð/2 ¡Â t5 ¡Â
>      ¥ð/2 && -¥ð/2 ¡Â t6 ¡Â ¥ð/2 && 0 ¡Â t7 ¡Â 2*¥ð}, {t1, t2, t3, t4, t5, t6,
> t7}]
>
> It displays the following error
> (Maximize::"objv" "The
>    objective function 2Cos^7(t1t2t3t4t5t6t7) contains a nonconstant
> expression (Cos^7) independent of variables {t1,t2,t3,t4,t5,t6,t7}")
>
>
> So, what I need is to maximize the function B, with t1,t2,t3,t4,t5,t6
> varying from -¥ð/2 to ¥ð/2 and t7 varying from 0 to 2¥ð.
>
> I hope someone can help me
>
> Thx a lot!
>
>


  • Prev by Date: Shared color scaling
  • Next by Date: Text XY-size control in 2D graphics?
  • Previous by thread: Maximize command - trigonometric function
  • Next by thread: Problems with Dynamic Updating and Java Runtime