spline#
- Lines.spline(p1='', p2='', p3='', p4='', p5='', p6='', xv1='', yv1='', zv1='', xv6='', yv6='', zv6='', **kwargs)#
Generates a segmented spline through a series of keypoints.
Mechanical APDL Command: SPLINE
- Parameters:
- p1
str Keypoints through which the spline is fit. At least two must be defined. If
P1= P, graphical picking is enabled and all remaining command fields are ignored (valid only in the GUI).- p2
str Keypoints through which the spline is fit. At least two must be defined. If
P1= P, graphical picking is enabled and all remaining command fields are ignored (valid only in the GUI).- p3
str Keypoints through which the spline is fit. At least two must be defined. If
P1= P, graphical picking is enabled and all remaining command fields are ignored (valid only in the GUI).- p4
str Keypoints through which the spline is fit. At least two must be defined. If
P1= P, graphical picking is enabled and all remaining command fields are ignored (valid only in the GUI).- p5
str Keypoints through which the spline is fit. At least two must be defined. If
P1= P, graphical picking is enabled and all remaining command fields are ignored (valid only in the GUI).- p6
str Keypoints through which the spline is fit. At least two must be defined. If
P1= P, graphical picking is enabled and all remaining command fields are ignored (valid only in the GUI).- xv1
str Location (in the active coordinate system) of the head of the “slope vector” corresponding to the slope at the
P1end of the spline. The tail of the vector is at the origin of the coordinate system.- yv1
str Location (in the active coordinate system) of the head of the “slope vector” corresponding to the slope at the
P1end of the spline. The tail of the vector is at the origin of the coordinate system.- zv1
str Location (in the active coordinate system) of the head of the “slope vector” corresponding to the slope at the
P1end of the spline. The tail of the vector is at the origin of the coordinate system.- xv6
str Location of the head of the “slope vector” corresponding to the slope at the
P6(or the last keypoint if fewer than six specified) end of the spline.- yv6
str Location of the head of the “slope vector” corresponding to the slope at the
P6(or the last keypoint if fewer than six specified) end of the spline.- zv6
str Location of the head of the “slope vector” corresponding to the slope at the
P6(or the last keypoint if fewer than six specified) end of the spline.
- p1
- Returns:
Notes
Warning
This function contains specificities regarding the argument definitions. Please refer to the command documentation for further explanations.
The output from this command is a series of connected lines (one line between each pair of keypoints) that together form a spline. Note that solid modeling in a toroidal coordinate system is not recommended.
Examples
Create a spline with 5 keypoints.
>>> k0 = mapdl.k('', 0, 0, 0) >>> k1 = mapdl.k('', 0.2, 0.2, 0) >>> k2 = mapdl.k('', 0.4, 0.3, 0) >>> k3 = mapdl.k('', 0.6, 0.5, 0) >>> k4 = mapdl.k('', 0.8, 0.3, 0) >>> lines = mapdl.spline(k0, k1, k2, k3, k4) >>> lines [1, 2, 3, 4]