Back to index

Functions | Variables
mesh.m File Reference

Go to the source code of this file.


 if (nargin==1) z
 if (is_matrix(z)) gset hidden3d
gset if (length(getenv("TEXMACS_PATH"))>0) gset output '/tmp/tmplot.eps'
endif gsplot (z')
 while (g==-1) sleep(1)
endwhile while (!feof(g)) f
 if (length(f)) P
endif endwhile fclose (g)
 disp (sprintf("%cverbatim:\n", 2))
 disp (setstr(P'))
 system ("rm /tmp/tmplot.eps")
endif else error ("mesh: argument must be a matrix")
endif elseif (nargin==3) if(is_vector(x)&&is_vector(y)&&is_matrix(z)) xlen
 if (xlen==columns(z)&&ylen==rows(z)) if(rows(y)
 zz (:, i+1)
endif gsplot (zz)
 error (msg)
endif elseif (is_matrix(x)&&is_matrix(y)&&is_matrix(z)) xlen
endif else error ("mesh: x, y, and z must have same dimensions")
endif else error ("mesh: x and y must be vectors and z must be a matrix")
endif else usage ("mesh (z)")


function mesh (x, y, z) P = [2
gset data style lines
gset surface
gset nocontour
gset noparametric
gset view
 g = fopen("/tmp/tmplot.eps")
 P = [P
 ylen = length (y)
endif len = 3 * xlen
 zz = zeros (ylen, len)
 k = 1
for i
endfor gset hidden3d
gset parametric
endif else msg = "mesh: rows (z) must be the same as length (y) and"

Function Documentation

disp ( sprintf("%cverbatim:\n", 2)  )
disp ( setstr(P')  )
endif elseif ( nargin  = =3)
endif elseif ( is_matrix(x)&&is_matrix(y)&&is_matrix(z)  )
endif else error ( "mesh: argument must be a matrix )
error ( msg  )
endif else error ( "mesh:  x,
y  ,
and z must have same dimensions"   
endif else error ( "mesh: x and y must be vectors and z must be a matrix )
endif endwhile fclose ( g  )
endif gsplot ( z'  )
endif gsplot ( zz  )
if ( nargin  = =1)
if ( is_matrix(z)  )
gset if ( length(getenv("TEXMACS_PATH"))  ,
if ( length(f )
if ( xlen  = =columns(z)&&ylen==rows(z))
system ( "rm /tmp/tmplot.eps"  )
endif else usage ( "mesh (z)"  )
while ( g  = =-1)
endwhile while ( feofg)
zz ( ,
i 1 

Variable Documentation


Definition at line 67 of file mesh.m.

g = fopen("/tmp/tmplot.eps")

Definition at line 62 of file mesh.m.

endfor gset hidden3d

Definition at line 96 of file mesh.m.

for i
Initial value:
          zz(:,i)   = x(k) * ones (ylen, 1)

Definition at line 90 of file mesh.m.

k = 1

Definition at line 89 of file mesh.m.

endif len = 3 * xlen

Definition at line 87 of file mesh.m.

gset data style lines

Definition at line 49 of file mesh.m.

function mesh(x, y, z) P = [2
msg = "mesh: rows (z) must be the same as length (y) and"

Definition at line 126 of file mesh.m.

gset nocontour

Definition at line 51 of file mesh.m.

Definition at line 52 of file mesh.m.

P = [P

Definition at line 71 of file mesh.m.

gset parametric

Definition at line 100 of file mesh.m.

gset surface

Definition at line 50 of file mesh.m.

gset view

Definition at line 53 of file mesh.m.

ylen = length (y)

Definition at line 82 of file mesh.m.

zz = zeros (ylen, len)

Definition at line 88 of file mesh.m.