AUTOMATIC MODELING OF THE SURFACES OF THE EQUAL SLOPE IN AUTOCAD SYSTEM THROUGH LANGUAGE AUTOLISP

Graphical computer modeling is a real possibility o f s lving problems on the formation of surfaces by a kinematic method. It is due to the presence of automated design systems, such as MathCad, Mathematika, AutoCad, etc. The advantag e of the AutoCad system is the presence of the built-in language of functional AutoLis p. Having a wide range of mathematical functions and functions for drawing graphic objects , the AutoLisp language allows you to write a program for drawing shells of any complexit y, n a particular case shells of the same ramp on the elliptical plane, the surface of the in volute helicoid, and then transferring the results to the AutoCAD environment. Playing objects in low motion makes it possible to compose mini-films about the formation of surfaces. Th e image of graphical constructions in three-dimensional space using the AutoCAD color pal ette enhances the expressiveness of the image of surfaces and their elements. The aim of the study is the possibility of modeling the surface of the equal slope ramp on an elliptical plane, carried out by its gradual dra wing in a slow dynamic mode with the creation of a mini-film that allows the surface to be d isplayed on the monitor screen.

Surfaces of the equal slope are used in architecture since ancient times. An example is the Greek theater ( fig. 1) [1]. Currently, they are increasingly used in projects of architectural ensembles, including combinations of geometric shapes. Museum of contemporary art (Niteroi, Brazil, architect Oscar Niemeyer) ( fig. 2) is one of them [2], etc. The surface of the equal slope is a ruled analytic surface having a constant angle of inclination between the rectilinear generatrix and the principal normal to the directing curve. The general theoretical basis for the formation of surfaces is given in the work of Krivoshapko S.N. and Ivanov V.N. [3].
In accordance with the definition given above, the surfaces of the equal slope are formed by a rectilinear generatrix, which in all positions has a constant angle of inclination α with the principal normals , , , … , to the m curve. If the directing curve is a plane line, for example, an ellipse, the linear generators lie in the planes П , П , П , … , П , normal to this curve ( fig. 3).
From the definition, the possibility of forming a surface of the equal slope on an elliptical plane by a kinematic method also follows.
Elements of the surface are the ellipse q -the directing line and the straight line m -the generator. The initial position of the surface elements is shown in Fig. 4.
The most suitable for forming the surface in the AutoCad system is the Loft function. As sections it is necessary to take the positions of the generator as it moves along the ellipse. Moving the generator is performed by the Move function.
To satisfy the condition of constancy of the angle between the generating straight line and the normal to the ellipse, it is necessary to set the coordinate system to the current point on the elliptic curve at each step of the construction and to direct the x axis along the normal in this curve. In order to establish the x-axis along the normal to the guide, the value of the derivative from the elliptic function and the angle γ between the tangent to the curve and the x-axis: γ arctg y , and then the angle β between the x-axis and the normal to the curve: β 90 . To form the surface the complex of programs has been developed, including user functions Sk10.lsp, Formsurface.lsp, etc. The initial data for constructing the surface are: the large and small semi-axes of the ellipse a, b, the slope angle α of the forming straight line to the normal , the length of the forming line -Lobr.
Algorithm of the program for the formation of surface compartments 1. Input of initial data is performed from the command line at the request of the program. The function Getreal is used.
1. An isometric view of NWiso is established. 2. An ellipse is constructed using the user-defined Elip function. The origin is at the intersection of the axes of the ellipse.
3. An empty selection is created for the forming lines of surfaces. The function -(setq ssr1 '()). 4. The initial generator is constructed from two points: pt1 and pte. The point pt1 is given on the contour of the ellipse at φ = 0, where φ is the angle between the radius vector of the ellipse point and the x axis. The point pte is defined in polar coordinates: (setq pte (polar pt1 (-pi alfar) lobr)). The construction of the generatrix is performed by the function: (command "pline" pt1 pte ""). The generating line is assigned the identifier en1, which allows you to enter it into the selection ssr1.
5. To calculate the coordinates of points of an ellipse and the derivative of an elliptic function, two user functions are created: El-pt, El1-pt. 6. To construct the surface compartments, a loop with parameters i 1 71 and φ.
The parameter i is required to form the name of the layer, the parameter φ is used to construct the generating lines.
The following operations are performed in the loop: • Create a layer name that corresponds to the i parameter and set it to the current one: (Setq nsloy (strcat "vent" (itoa i))) (Command "layer" "s" nsloy ""). • Transfer of the coordinate axes to the ellipse point pt2, corresponding to the angle φ, determined by the relation φ = φ + ∆φ.
• Two user functions Usk1 and Usk2 are created to orient the coordinate axes along the normal to the ellipse. The angle γ needed to rotate the coordinate axes around the z axis is determined using functions (Setq y11 (/ b (* a -1.0 (/ (sin fi) (cos fi))))) (Setq gamma (atan y11)). A subsequent rotation of the coordinate system about the x axis through an angle "90 around the y axis achieves the setting of the coordinate axes so that the x axis is directed along the normal to the ellipse.
At the end of the cycle, a Skat-bl block is created, containing the surface compartments and the forming lines.
To visualize the process of surface formation, a user function Sk11.lsp is created, which includes the function Form-surface.lsp, which visualizes the process of surface formation by "unfreezing" the layers with the compartments contained in the Skat-bl block. Fig. 5 shows the process of surface formation, the surface skeleton is in Fig. 6, the surface of the same slope is represented in Fig. 7. The code for the Form-surface.lsp function is given below: (Defun form-surface (k) (Repeat k (Setq nsloyi (strcat "vent" (itoa i))) (Command "layer" "thaw" nsloyi "") (Command "erase" s1 "") (Setq s2 (ssget "x" (list (cons 8 (substr nsloyi 1 6))))) (Setq s1 s2) (Command "delay" 300) (Setq i (+ i 1)) )) The developable evolvent helicoid is formed by the motion of a straight forming line-q, which is in all positions the tangent to the cylindrical helical line -the cuspidal edge of the surface, parallel to the guide cone [4]. The evolvent of the circle of the lower base of the cylinder is the guiding line m (fig.8).
The projection of the formation line in all positions on one side is a tangent of the circumference of the cylinder, the other normal to the guide line m. Consequently, the angle between the generator and its projection is the angle between the generatrix and the principal normal to the directing curve, so the evolvent helicoid belong to the surface of the same slope ( fig. 8).
Let us consider the formation of an evolvent helicoid by the motion of a rectilinear forming line q on two helical lines, one of which lies on a cylinder of radius r and is called the cuspidal edge, the forming line q at all positions is tangent to the line m and forms an angle α with the horizontal plane. The second line n (Fig. 9) is the guide. The radius of the cylinder for helix n is BD. To construct the surface of a helicoid, the length of the forming line and the angle α of its inclination to the horizontal plane are given. The helixes m and n are drawn by the user function Gelisa (r), where r is the radius of the cylinder. The surface of the helicoid is formed in the AutoCAD system through a program in the language of AutoLISP [5].
The generating lines are formed in a cycle with the parameter φ -the angle of rotation of the radius of the basic circle. At each step of the cycle, the point A rotates by an angle dφ and moves upward by a distance ds. From the point A for each value of the angle φ, the generating line AB is drawn at a given slope angle α to the segment DB. The names of the generators are entered in the SSR list, the use of which by the AutoLISP functions Foreach and Loft allows to form the surface and its compartments.
The surface can be constructed instantly at the end of the cycle by the Loft function or gradually in a cycle by successively drawing the surface compartments. In the second case, the process of formation of a surface along an array of generating lines is observed on the screen. In Fig. 10 shows the surface of the evolvent helicoid in the process of its formation.
If during the formation of the surface each formation line and corresponding compartment are placed in the layer assigned to them, then at the end of the cycle a block is created that includes all the surface compartments and formation lines.  Visualization of the process of surface formation is provided by the user-defined function Form-surface.lsp. In this case, the surface is formed after the forming line, moving along the guide n. (Fig. 11).
Thus, the simulation of the surface of the same slope was made possible in Au-toCAD thanks to programs written in AutoLisp.
The visualization of the process of formation of cyclic surfaces with variable radius of generatrix circles or of umbrella-type and umbrella surfaces with radial damping waves in the central point given in the works [6], [7].