Re: Tricky visualization of maximization problem

• To: mathgroup at smc.vnet.net
• Subject: [mg71016] Re: Tricky visualization of maximization problem
• From: "Wei-Yang Lin" <WeiYang.Lin at gmail.com>
• Date: Sat, 4 Nov 2006 23:07:13 -0500 (EST)
• References: <eihm95\$ov4\$1@smc.vnet.net>

```The eq. x1^2+x2^2==1 is a cylinder in 3-dimensional space.

You may use ParametricPlot3D to plot it.

ParametricPlot3D[{Cos[t],Sin[t],h},{t,0,2Pi},{h,0,1}]

To see the intersection between them:

ParametricPlot3D[{Cos[t],Sin[t],Cos[t]^2+4Cos[t]Sin[t]+3Sin[t]^2},{t,0,2Pi}]

Plot[Cos[t]^2+4Cos[t]Sin[t]+3Sin[t]^2,{t,0,2Pi}]

Good luck!

Uwe Ziegenhagen wrote:
> Hi,
>
> I want to maximize
>
> x1^2 + 4*x1*x2 + 3*x2^2  (eq.1)
>
> under the constraint
>
> x1^2 + x2^2 == 1 (eq. 2)
>
> So far no problem, Maximize gives me 2 + sqrt(5)
>
> But how can I display this visually?
>
> For eq. 1 I can use Plot3D[], for eq. 2 ImplicitPlot[] but how to have
> them in one picture?
>
>
> Thanks in advance,
>
>
> Uwe

```

• Prev by Date: Re: Matrix OutputDavid Bailey,http://www.dbaileyconsultancy.co.uk
• Next by Date: Re: Matrix Output
• Previous by thread: Re: Tricky visualization of maximization problem
• Next by thread: Re: Tricky visualization of maximization problem