MathGroup Archive 1998

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

Search the Archive

Re: Plotting points in 3D


  • To: mathgroup@smc.vnet.net
  • Subject: [mg11482] Re: Plotting points in 3D
  • From: weber@math.uni-bonn.de (Matthias Weber)
  • Date: Fri, 13 Mar 1998 12:21:28 -0500
  • Organization: RHRZ - University of Bonn (Germany)
  • References: <6e888n$nno@smc.vnet.net>

In article <6e888n$nno@smc.vnet.net>, Sofiane Ramdani
<ramdani@univ-tln.fr> wrote:

> Hi all,
> 
> I've wrote a program that solves an implicit equation that looks like :
> f(x,y,z)=0. In fact, my program actually find a "z" for some values of
> "x" and "y". Then, using "Plot3D", I've plotted a 3D surface of "z" as
> a
> 
> numerical function of x and y. After this, I've evaluated new points :
> (x1,y1,z1) in a new 3D basis.
> I'm trying now to plot these new points using the values of "x1", "y1"
> and "z1".
> Is there any way to do this?
> 
> Thanks for any answer.

I am not sure that I understand your question, so I will give three
answers:

1.) You first might want to give ContourPlot3D a try, which can plot
implicitly defined surfaces as yours to some extent (this is a hard
problem in general).

2.) If your coordinate transformation is orthogonal, you can
    achieve is (probably) by choosing another ViewPoint
    in Show.

2.) If your coordinate transformation is not orthogonal, you have
    to work a bit harder:
    From Plot3D you get SurfaceGraphics object which can be converted
    to a Graphics3D object:

sg=Plot3D[...];

g1=Graphics3D[sg];

This is not as mysterious as you might think, and it is very usefull to
have a closer look at it.

g1 looks like

Graphics3D[{Polygon[{p1,p2,p3...}],Polygon[...],...}, <options>]

The p's are of the form {x1,x2,x3} and represent the points in 3-space
which are the values calculated by Plot3D using your equation solver.

Now suppose that you have your coordinate transformation given in the
form
trans[{x1_, x2_, x3_}] := ...
yielding a list of the three new coordinates.

Then you can just write

g2 = g1 /. Polygon[li_] -> Polygon[trans[li]]; Show[g2]

to get your tansformed object.

I hope one of the answers helped.


Matthias



  • Prev by Date: Re: Two questions
  • Next by Date: Re: Extracting polynomial coefficients?
  • Prev by thread: Plotting points in 3D
  • Next by thread: Re: Plotting points in 3D