Octave graphic add-on, Octaviz



česky

2.4 Cone, Frustum_cone



Function file: cone(m,n,p,r,v,q,prop,val)


This function plots a cone. Definition:
  • 1 cone - centre in [m,n,p], radius "r", high "v" and quality "q"; all values are scalar
  • n-cones - centres in [m,n,p], radiuses "r", highs "v" and qualities "q"; all values are vectors

Parameters of function:
Parameters m,n,p describe centres of the cone in axes x,y,z.
Parameter r describe radius of the cone.
Parameter v describe high of the cone.
Parameter q is for change compute points on objects, so it is quality of drawing object.
Parameters prop, val are using for change color or opacity. These parameters are optional.


Example:
cone([0,2],[0,3.2],[0,-1.2],[2,3],[4,5],[40,50],["c","o"],[[1 0.5 0.5],0.5]);



download m-file



Function file: frustum_cone(m,n,p,r1,r2,v,q,prop,val)


This function plots a frustum cone. Definition:
  • 1 frustum cone - centre in [m,n,p], radius "r1", "r2", high "v" and quality "q"; all values are scalar
  • n-frustum cones - centres in [m,n,p], radiuses "r1", "r2", highs "v" and qualities "q"; all values are vectors

Parameters of function:
Parameters m,n,p describe center of the frustum cone in axes x,y,z.
Parameters r1,r2 describe radius of base of the frustum cone - r1 and upper base - r2.
Parameter v describe high of the frustum cone.
Parameter q is for change compute points on objects, so it is quality of drawing object.
Parameters prop, val are using for change color or opacity. These parameters are optional.


Example:
frustum_cone([0,2],[0,3.2],[0,-1.2],[4,3],[2,1],[4,5],[40,50],["c","o"],[[1 0.5 0.5],0.5]);








<<< 2.3 Cylinder, sphere 2.5 Function using parametric formulation >>>

© 2008 David Prokop