diff options
author | Shashank | 2017-05-29 12:40:26 +0530 |
---|---|---|
committer | Shashank | 2017-05-29 12:40:26 +0530 |
commit | 0345245e860375a32c9a437c4a9d9cae807134e9 (patch) | |
tree | ad51ecbfa7bcd3cc5f09834f1bb8c08feaa526a4 /modules/graphics/macros/fac3d1.sci | |
download | scilab_for_xcos_on_cloud-0345245e860375a32c9a437c4a9d9cae807134e9.tar.gz scilab_for_xcos_on_cloud-0345245e860375a32c9a437c4a9d9cae807134e9.tar.bz2 scilab_for_xcos_on_cloud-0345245e860375a32c9a437c4a9d9cae807134e9.zip |
CMSCOPE changed
Diffstat (limited to 'modules/graphics/macros/fac3d1.sci')
-rwxr-xr-x | modules/graphics/macros/fac3d1.sci | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/modules/graphics/macros/fac3d1.sci b/modules/graphics/macros/fac3d1.sci new file mode 100755 index 000000000..918583d76 --- /dev/null +++ b/modules/graphics/macros/fac3d1.sci @@ -0,0 +1,46 @@ +// Scilab ( http://www.scilab.org/ ) - This file is part of Scilab +// Copyright (C) INRIA +// This file must be used under the terms of the CeCILL. +// This source file is licensed as described in the file COPYING, which +// you should have received as part of this distribution. The terms +// are also available at +// http://www.cecill.info/licences/Licence_CeCILL_V2.1-en.txt + +function fac3d1(x,y,z,T,A,leg,flags,ebox) + + // Copyright INRIA + + [lhs,rhs]=argn(0); + + write(%io(2),"WARNING : fac3d1 is obsolete see plot3d plot3d1 instead"); + + if rhs <= 0 then // demo + deff("[x,y,z]=sph(alp,tet)",["x=r*cos(alp).*cos(tet)+orig(1)*ones(tet)"; .. + "y=r*cos(alp).*sin(tet)+orig(2)*ones(tet)"; .. + "z=r*sin(alp)+orig(3)*ones(tet)"]); + r=1; + orig=[0 0 0]; + [x1,y1,z1]=eval3dp(sph,linspace(-%pi/2,%pi/2,40),linspace(0,%pi*2,20)); + [n1,m1]=size(x1); + r=1/2; + orig=[-1 0 0]; + [x2,y2,z2]=eval3dp(sph,linspace(-%pi/2,%pi/2,40),linspace(0,%pi*2,20)); + [n2,m2]=size(x2); + x=[x1 x2]; + y=[y1 y2]; + z=[z1 z2]; + plot3d1(x,y,z); + return + end + + select rhs + case 3 then plot3d1(x,y,z) + case 4 then plot3d1(x,y,z,T) + case 5 then plot3d1(x,y,z,T,A) + case 6 then plot3d1(x,y,z,T,A,leg) + case 7 then plot3d1(x,y,z,T,A,leg,flags) + case 8 then plot3d1(x,y,z,T,A,leg,flags,ebox) + else error(msprintf(gettext("%s: Wrong number of input arguments: %d to %d expected.\n"), "fac3d1", 3, 8)); + end + +endfunction |