Re: Re: Re: multiple 3d plots
- To: mathgroup at smc.vnet.net
- Subject: [mg56385] Re: [mg56347] Re: [mg56304] Re: multiple 3d plots
- From: DrBob <drbob at bigfoot.com>
- Date: Sat, 23 Apr 2005 01:16:18 -0400 (EDT)
- References: <200504221023.GAA18819@smc.vnet.net>
- Reply-to: drbob at bigfoot.com
- Sender: owner-wri-mathgroup at wolfram.com
Wow. That is gorgeous! Bobby On Fri, 22 Apr 2005 06:23:40 -0400 (EDT), David Park <djmp at earthlink.net> wrote: > I had to try this with the DrawGraphics package from my web site. I will > send you a .gif image separately so you can see the result if you don't have > the package. > > This looks like much more work, but I think we get a nicer plot. > > First, let's solve for the intersection, which we can do in this case. > > Solve[x^2*y == 3*(x/y), y] > {{y -> -(Sqrt[3]/Sqrt[x])}, {y -> Sqrt[3]/Sqrt[x]}} > > There are two solutions over a wider domain, so let's look at both > solutions. We can calculate the z value for a given x by > > 3*(x/y) /. y -> Sqrt[3/x] > Sqrt[3]/(1/x)^(3/2) > > with a similar expression for the negative solution. Then here is the plot. > > Needs["DrawGraphics`DrawingMaster`"] > > Draw3DItems[ > {SurfaceColor[PaleGreen], EdgeForm[ColorMix[PaleGreen, Black][0.3]], > Draw3D[x^2*y, {x, 0, 6}, {y, -3, 3}, PlotPoints -> 20], > > SurfaceColor[LightSteelBlue], EdgeForm[ColorMix[LightSteelBlue, > Black][0.3]], > Draw3D[3*(x/y), {x, 0, 6}, {y, -3, -0.1}, PlotPoints -> 20], > Draw3D[3*(x/y), {x, 0, 6}, {y, 0.1, 3}, PlotPoints -> 20], > > Red, AbsoluteThickness[2], > ParametricDraw3D[{x, Sqrt[3/x], Sqrt[3]/(1/x)^(3/2) + 1}, {x, 0.35, 6}, > PlotPoints -> 20], > ParametricDraw3D[{x, -Sqrt[3/x], -(Sqrt[3]/(1/x)^(3/2)) + 1}, {x, 0.35, > 6}, > PlotPoints -> 20]}, > > NeutralLighting[0.3, 0.5, 0.1], > PlotRange -> {-40, 40}, > BoxRatios -> {1, 1, 0.5}, > BoxStyle -> Gray, > Axes -> True, > AxesLabel -> {x, y, ""}, > Ticks -> {CustomTicks[Identity, {0, 6, 3, 3}], > CustomTicks[Identity, {-3, 3, 3, 3}], CustomTicks[Identity, > {-30, 30, 30, 3}]}, > PlotLabel -> SequenceForm["Intersection of ", x^2*y," and ",3*(x/y)], > ViewPoint -> {2.493, -0.343, 2.262}, > Background -> Linen, > ImageSize -> 450]; > > I used two different colors for the two surfaces and NeutralLighting so the > colors would not be overwhelmed by the regular color saturation of the > lighting. The 3x/y surface was plotted in two parts to eliminate the 'return > surface' at y = 0. The intersection was plotted with a thick red line and > raised slightly so it would better display. EdgeForm was used to subdue the > surface 'meshes' and make a different shade of the surface color. > > David Park > djmp at earthlink.net > http://home.earthlink.net/~djmp/ > > From: juejung [mailto:juejung at indiana.edu] To: mathgroup at smc.vnet.net > > okay, this seems to do the trick. > but the show command doesn't use the color i specified for graph p2. any, > idea? > > > p1 = Plot3D[x^2*y, {x, 1, 2}, {y, 1, 2}]; > p2 = Plot3D[{3*x*(1/y),Hue[.4]}, {x, 1, 2}, {y, 1, 2}]; > Show[p1, p2]; > > > > > > > -- DrBob at bigfoot.com
- Follow-Ups:
- Re: Re: Re: Re: multiple 3d plots
- From: Pratik Desai <pdesai1@umbc.edu>
- Re: Re: Re: Re: multiple 3d plots
- References:
- Re: Re: multiple 3d plots
- From: "David Park" <djmp@earthlink.net>
- Re: Re: multiple 3d plots