File: geom3d.cat

package info (click to toggle)
scilab 2.4-1
  • links: PTS
  • area: non-free
  • in suites: potato, slink
  • size: 55,196 kB
  • ctags: 38,019
  • sloc: ansic: 231,970; fortran: 148,976; tcl: 7,099; makefile: 4,585; sh: 2,978; csh: 154; cpp: 101; asm: 39; sed: 5
file content (37 lines) | stat: -rw-r--r-- 1,103 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37

geom3d(2)                      Scilab Function                      geom3d(2)
NAME
  geom3d -  projection from 3D on 2D

CALLING SEQUENCE
  [x,y]=geom3d(x1,y1,z1)

PARAMETERS

  x1,y1,z1       : real matrices of the same size (points in R3)

  x,y            : real matrices of the same size as x1,y1 or z1

DESCRIPTION
  After having used a 3d plotting function as plot3d, plot3d1 and param3d,
  this function gives the correspondence between a point in R3 space
  (x1(i),y1(i),z1(i)) and the corresponding point in the projected graphic
  plan (x(i),y(j)).  all the graphical primitives working on (x,y) can then
  be used for superposition on a plot3d

EXAMPLE
  deff("[z]=surf(x,y)","z=sin(x)*cos(y)");
  t=%pi*(-10:10)/10;
  fplot3d(t,t,surf,35,45,"X@Y@Z");
      //Gives a plot3d
      //now  (t,t,sin(t).*cos(t) ) is a curve on the surface
      //which can be drawn using param3d or the following code
  [x,y]=geom3d(t,t,sin(t).*cos(t));
  xpoly(x,y,"lines")
      //adding a comment
  [x,y]=geom3d([0,0],[0,0],[5,0]);
  xsegs(x,y);
  xstring(x(1),y(1)," The point (0,0,0)");

AUTHOR
  J.Ph.C.