CN108327287B - A kind of rapid generation of three periods minimal surface 3 D-printing slicing profile - Google Patents
A kind of rapid generation of three periods minimal surface 3 D-printing slicing profile Download PDFInfo
- Publication number
- CN108327287B CN108327287B CN201810040995.2A CN201810040995A CN108327287B CN 108327287 B CN108327287 B CN 108327287B CN 201810040995 A CN201810040995 A CN 201810040995A CN 108327287 B CN108327287 B CN 108327287B
- Authority
- CN
- China
- Prior art keywords
- slice
- line segment
- quadrangle
- curved surface
- quadrilateral
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000007639 printing Methods 0.000 title claims abstract description 8
- 230000014509 gene expression Effects 0.000 claims abstract description 16
- 238000009826 distribution Methods 0.000 claims abstract description 6
- 238000000034 method Methods 0.000 claims description 43
- 238000004321 preservation Methods 0.000 claims 1
- 238000007796 conventional method Methods 0.000 abstract 1
- 238000010146 3D printing Methods 0.000 description 17
- 238000004519 manufacturing process Methods 0.000 description 10
- 238000005516 engineering process Methods 0.000 description 9
- 239000010410 layer Substances 0.000 description 7
- 230000006870 function Effects 0.000 description 5
- 238000012545 processing Methods 0.000 description 4
- 238000013461 design Methods 0.000 description 3
- 238000004364 calculation method Methods 0.000 description 2
- 239000000463 material Substances 0.000 description 2
- 239000002356 single layer Substances 0.000 description 2
- 238000007792 addition Methods 0.000 description 1
- 239000000654 additive Substances 0.000 description 1
- 230000000996 additive effect Effects 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 239000012620 biological material Substances 0.000 description 1
- 238000004113 cell culture Methods 0.000 description 1
- 238000005520 cutting process Methods 0.000 description 1
- 230000007547 defect Effects 0.000 description 1
- 238000001514 detection method Methods 0.000 description 1
- 238000010586 diagram Methods 0.000 description 1
- 238000013173 literature analysis Methods 0.000 description 1
- 238000003754 machining Methods 0.000 description 1
- 238000003801 milling Methods 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000005457 optimization Methods 0.000 description 1
- 230000000737 periodic effect Effects 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
- 238000012360 testing method Methods 0.000 description 1
Classifications
-
- B—PERFORMING OPERATIONS; TRANSPORTING
- B29—WORKING OF PLASTICS; WORKING OF SUBSTANCES IN A PLASTIC STATE IN GENERAL
- B29C—SHAPING OR JOINING OF PLASTICS; SHAPING OF MATERIAL IN A PLASTIC STATE, NOT OTHERWISE PROVIDED FOR; AFTER-TREATMENT OF THE SHAPED PRODUCTS, e.g. REPAIRING
- B29C64/00—Additive manufacturing, i.e. manufacturing of three-dimensional [3D] objects by additive deposition, additive agglomeration or additive layering, e.g. by 3D printing, stereolithography or selective laser sintering
- B29C64/30—Auxiliary operations or equipment
- B29C64/386—Data acquisition or data processing for additive manufacturing
-
- B—PERFORMING OPERATIONS; TRANSPORTING
- B33—ADDITIVE MANUFACTURING TECHNOLOGY
- B33Y—ADDITIVE MANUFACTURING, i.e. MANUFACTURING OF THREE-DIMENSIONAL [3-D] OBJECTS BY ADDITIVE DEPOSITION, ADDITIVE AGGLOMERATION OR ADDITIVE LAYERING, e.g. BY 3-D PRINTING, STEREOLITHOGRAPHY OR SELECTIVE LASER SINTERING
- B33Y50/00—Data acquisition or data processing for additive manufacturing
Landscapes
- Chemical & Material Sciences (AREA)
- Engineering & Computer Science (AREA)
- Materials Engineering (AREA)
- Manufacturing & Machinery (AREA)
- Physics & Mathematics (AREA)
- Mechanical Engineering (AREA)
- Optics & Photonics (AREA)
Abstract
Description
技术领域technical field
本发明涉及三维打印计算机辅助制造(Computer aided manufacturing,CAM)技术领域,尤其是涉及一种三周期极小曲面三维打印切片轮廓的快速生成方法。The invention relates to the technical field of three-dimensional printing computer aided manufacturing (CAM), in particular to a method for rapidly generating three-period minimal curved surface three-dimensional printing slice profiles.
背景技术Background technique
三维打印技术是一种基于层片叠加的先进制造技术,又被称为快速原型技术或增材制造技术。不同于传统机加工等不断削减材料以得到设计形状的工艺方法,三维打印技术利用各类材料,借助计算机辅助设备层层叠加得到设计模型,特别适合复杂结构的快速制造成型。三维打印切片轮廓生成是影响制造最终精度与效率的关键环节。3D printing technology is an advanced manufacturing technology based on layer stacking, also known as rapid prototyping technology or additive manufacturing technology. Different from traditional machining methods that continuously cut materials to obtain design shapes, 3D printing technology uses various materials to obtain design models with the help of computer-aided equipment layer by layer, which is especially suitable for rapid manufacturing of complex structures. The generation of 3D printing slice contour is a key link that affects the final precision and efficiency of manufacturing.
为了在精度与效率之间找到比较理想的平衡点,国内外学者在切片轮廓生成方面做了大量的工作,针对不同的三维模型数据,提出了各类切片生成方法。当前在三维打印领域,STL是最为常用的模型数据格式。STL用大量的三角面片逼近设计模型形状,数据结构简单,便于处理。但是为了提高建模精度,必须大大增加面片数量,进而消耗大量的内存和处理时间。特别在建模复杂拓扑结构时,STL的劣势表现的更为明显,大量的面片和一些难以处理的面片缺陷经常会导致切片轮廓生成的失败。In order to find an ideal balance between accuracy and efficiency, scholars at home and abroad have done a lot of work in the generation of slice contours, and proposed various slice generation methods for different 3D model data. Currently in the field of 3D printing, STL is the most commonly used model data format. STL uses a large number of triangular patches to approximate the shape of the design model, and the data structure is simple and easy to handle. However, in order to improve the modeling accuracy, the number of patches must be greatly increased, which in turn consumes a lot of memory and processing time. Especially when modeling complex topological structures, the disadvantage of STL is more obvious. A large number of patches and some intractable patch defects often lead to the failure of slice contour generation.
三周期极小曲面TPMS(Triply Periodic Minimal Surfaces)是一种具有复杂拓扑结构的隐式曲面。其光滑的表面以及内外连通的孔洞结构在工程领域有着广泛的应用。三维打印具有制造此类复杂结构的天然优势。Melchels等人将设计的TPMS结构保存为STL文件利用三维打印工艺进行制造,进而作为组织工程支架进行细胞培养(参见Melchels FP W,Bertoldi K,Gabbrielli R,et al.Mathematically defined tissue engineeringscaffold architectures prepared by stereolithography[J].Biomaterials,2010,31(27):6909-6916.);Li等人生成STL格式的TPMS结构作为三维打印模型的填充结构,实现打印轻量化目的(参见Li D,Dai N,Jiang X,et al.Interior structural optimizationbased on the density-variable shape modeling of 3D printed objects[J].TheInternational Journal of Advanced Manufacturing Technology,2016,83(9-12):1627-1635)。切片线段排序处理方面,Kim提出了一种网格模型的切片轮廓暴力生成方法,方法实施简单但时间复杂度高达O(n2)(参见Kim H C.Tool path generation forcontour parallel milling with incomplete mesh model[J].The InternationalJournal of Advanced Manufacturing Technology,2010,48(5):443-454);Lin等人提出了一种针对STL切片线段的优化排序算法,时间复杂度O(nlogn)(参见Lin Z,Fu J,Shen H,et al.Efficient cutting area detection in roughing process for meshedsurfaces[J].The International Journal of Advanced Manufacturing Technology,2013,69(1-4):525-530)。Triply Periodic Minimal Surfaces (TPMS) are implicit surfaces with complex topology. Its smooth surface and internal and external connected hole structure have a wide range of applications in the engineering field. 3D printing has a natural advantage in making such complex structures. Melchels et al. saved the designed TPMS structure as an STL file for fabrication using a three-dimensional printing process, and then used as a tissue engineering scaffold for cell culture (see Melchels FP W, Bertoldi K, Gabbrielli R, et al. Mathematically defined tissue engineering scaffold architectures prepared by stereolithography [J].Biomaterials,2010,31(27):6909-6916.); Li et al. generated the TPMS structure in STL format as the filling structure of the 3D printing model to achieve the purpose of lightweight printing (see Li D, Dai N, Jiang X, et al. Interior structural optimization based on the density-variable shape modeling of 3D printed objects[J]. The International Journal of Advanced Manufacturing Technology, 2016, 83(9-12):1627-1635). For the processing of slice line segment sorting, Kim proposed a method for violent generation of slice contours for mesh models. The method is simple to implement but has a time complexity of up to O(n 2 ) (see Kim H C. Tool path generation for contour parallel milling with incomplete mesh model [J]. The International Journal of Advanced Manufacturing Technology, 2010, 48(5): 443-454); Lin et al. proposed an optimized sorting algorithm for STL slice line segments with a time complexity of O(nlogn) (see Lin Z , Fu J, Shen H, et al. Efficient cutting area detection in roughing process for meshedsurfaces[J]. The International Journal of Advanced Manufacturing Technology, 2013, 69(1-4):525-530).
根据文献分析可知,当前利用三维打印技术制造三周期极小曲面均需先生成STL模型,再进行基于STL的切片。由于结构错综复杂,一般生成的STL模型文件较大,需要消耗很多内存和处理时间。当前的一些切片线段排序算法在处理大数据量下排序问题时效率低下,无法高效生成切片轮廓。此外,未发现任何关于三周期极小曲面切片轮廓生成方法的文献。According to literature analysis, the current use of 3D printing technology to manufacture three-period minimal surfaces requires first generating STL models, and then performing STL-based slicing. Due to the intricate structure, the generally generated STL model file is large, which consumes a lot of memory and processing time. Some current slicing line sorting algorithms are inefficient when dealing with large data volumes and cannot efficiently generate slicing contours. Furthermore, no literature was found on the method for generating the profile of three-period minimal surface slices.
发明内容SUMMARY OF THE INVENTION
为了解决现有基于STL模型的三周期极小曲面三维打印切片效率低、消耗内存大的缺点,本发明提供了一种三周期极小曲面三维打印切片轮廓的快速生成方法。通过构建切片四边形网格,快速实现三周期极小曲面的直接切片分层,避免传统方法STL模型的生成。同时充分利用切片四边形网格和切片线段的拓扑关系,快速进行切片线段排序生成最终切片轮廓,时间复杂度仅为线性O(n)。该方法稳定可靠,可以实现三周期极小曲面三维打印切片轮廓的快速生成。In order to solve the shortcomings of low efficiency and large memory consumption of the existing three-period minimal surface 3D printing slices based on the STL model, the present invention provides a rapid generation method for three-period minimal surface 3D printing slice profiles. By constructing a slicing quadrilateral mesh, the direct slicing and layering of three-period minimal surfaces can be quickly realized, avoiding the generation of STL models by traditional methods. At the same time, the topological relationship between the slicing quadrilateral grid and the slicing line segment is fully utilized, and the slicing line segment is quickly sorted to generate the final slicing outline, and the time complexity is only linear O(n). The method is stable and reliable, and can realize the rapid generation of three-period minimal surface three-dimensional printing slice contours.
为实现上述发明目的,本发明提供以下技术方案:In order to realize the above-mentioned purpose of the invention, the present invention provides the following technical solutions:
一种三周期极小曲面三维打印切片轮廓的快速生成方法,包括以下步骤:A method for rapidly generating slice profiles for three-period minimal surface three-dimensional printing, comprising the following steps:
步骤1:输入待切片的三周期极小曲面的表达式f(x,y,z)=c,,切片厚度h,切片四边形网格分辨率n,其中c为曲面临界值常数,x∈[a0,a1],y∈[b0,b1],z∈[c0,c1];Step 1: Input the expression f(x,y,z)=c of the three-period minimal surface to be sliced, the slice thickness h, the slice quadrilateral mesh resolution n, where c is the surface critical value constant, x∈[ a 0 ,a 1 ], y∈[b 0 ,b 1 ], z∈[c 0 ,c 1 ];
步骤2:根据三周期极小曲面的坐标分布范围及切片厚度,生成曲面对应区域的切片四边形网格;Step 2: According to the coordinate distribution range and slice thickness of the three-period minimal surface, generate a sliced quadrilateral grid of the corresponding area of the surface;
步骤3:根据三周期极小曲面表达式f(x,y,z)=c,线性插值计算曲面和每层切片四边形网格的切片线段;Step 3: According to the three-period minimal surface expression f(x,y,z)=c, linearly interpolate the surface and slice line segments of each layer of sliced quadrilateral grid;
步骤4:保存切片线段和与该切片线段对应的切片四边形网格中四边形的拓扑关系;Step 4: Save the topological relationship between the slice line segment and the quadrilateral in the slice quadrilateral grid corresponding to the slice line segment;
步骤5:根据切片线段和与该切片线段对应的切片四边形网格中四边形的拓扑关系,对切片线段进行排序;Step 5: Sort the sliced line segments according to the topological relationship between the sliced line segment and the quadrilateral in the sliced quadrilateral grid corresponding to the sliced line segment;
步骤6:将所有排序后生成的切片轮廓以CLI文件格式输出保存。Step 6: Save all sorted slice contours as output in CLI file format.
其中,所述生成曲面对应区域的切片四边形网格的具体过程为:Wherein, the specific process of generating the sliced quadrilateral mesh of the corresponding area of the surface is as follows:
首先,根据切片厚度h,将曲面对应区域分成个平面;First, according to the slice thickness h, the corresponding area of the surface is divided into a plane;
然后对于平面根据切片四边形网格分辨率n,分别沿x、y方向分别生成j个平行线,其中:then for the plane According to the slicing quadrilateral grid resolution n, j parallel lines are generated along the x and y directions respectively, where:
平行线 parallel lines
平行线 parallel lines
平行线xj和平行线yj正交,生成曲面对应区域的切片四边形网格。Parallel lines x j and parallel lines y j are orthogonal to generate a sliced quadrilateral grid of the corresponding area of the surface.
优选地,所述步骤3的具体过程为:Preferably, the specific process of step 3 is:
将每层切片四边形网格的顶点坐标代入三周期极小曲面函数表达式中,对于四边形边P1P2,其中两个顶点的三维坐标为P1(x1,y1,z1),P2(x2,y2,z2),利用线性插值方法计算得到切片线段端点P0:Substitute the vertex coordinates of each sliced quadrilateral mesh into the three-period minimal surface function expression, for the quadrilateral side P 1 P 2 , the three-dimensional coordinates of the two vertices are P 1 (x 1 , y 1 , z 1 ), P 2 (x 2 , y 2 , z 2 ), using the linear interpolation method to calculate the endpoint P 0 of the slice line segment:
即可得到曲面和所有切片四边形网格的切片线段。You can get the sliced segments of the surface and all sliced quad meshes.
利用该方法即可得到曲面和所有切片层四边形网格的切片线段。Using this method, the slice segments of the surface and quadrilateral meshes of all slice layers can be obtained.
优选地,所述步骤4的具体过程为:Preferably, the specific process of step 4 is:
建立切片线段数据结构和四边形数据结构,切片线段数据结构保存切片线段的2个顶点信息和与切片线段对应的相交四边形信息,四边形数据结构保存四边形的4个顶点信息和与四边形对应的切片线段信息,以此建立所有切片线段和与该切片线段对应的四边形的对应拓扑关系。Establish a slice line segment data structure and a quadrilateral data structure. The slice line segment data structure saves the 2 vertex information of the slice line segment and the intersecting quadrilateral information corresponding to the slice line segment, and the quadrilateral data structure saves the four vertex information of the quadrilateral and the slice line segment information corresponding to the quadrilateral , so as to establish the corresponding topological relationship between all slice line segments and the quadrilateral corresponding to the slice line segment.
优选地,所述步骤5的具体过程为:Preferably, the specific process of step 5 is:
步骤5-1:对于一条未排序的切片线段,找到与该切片线段对应的相交四边形;Step 5-1: For an unsorted slice segment, find the intersecting quadrilateral corresponding to the slice segment;
步骤5-2:根据该四边形坐标,在四边形网格中找到与该四边形相邻的四边形;Step 5-2: According to the coordinates of the quadrilateral, find the quadrilateral adjacent to the quadrilateral in the quadrilateral grid;
步骤5-3:判断该相邻的四边形中是否存在与该相邻的四边形对应的切片线段;Step 5-3: determine whether there is a slice line segment corresponding to the adjacent quadrilateral in the adjacent quadrilateral;
步骤5-4:找到和当前切片线段拥有相同坐标的相邻线段;Step 5-4: Find the adjacent line segment with the same coordinates as the current slice line segment;
步骤5-5:重复步骤5-1至步骤5-4即可完成切片线段的排序,有序的切片线段即为最终的切片轮廓。Step 5-5: Repeat steps 5-1 to 5-4 to complete the sorting of slice line segments, and the ordered slice line segments are the final slice outlines.
与现有技术相比,本发明具有的优点为:Compared with the prior art, the present invention has the following advantages:
利用分层切片网格,根据三周期极小曲面的函数表达式、坐标分布范围以及切片厚度直接生成分层切片线段,避免了传统方法需要首先生成STL网格模型再切片的缺点,节省了处理时间与内存消耗。此外,充分利用切片线段与切片网格四边形的拓扑关系,快速排序切片线段生成切片轮廓,时间复杂度仅为线性O(n)。本发明方法稳定可靠,可以高效生成三周期极小曲面的三维打印切片轮廓。Using the layered slice grid, the layered slice line segment is directly generated according to the function expression, coordinate distribution range and slice thickness of the three-period minimal surface, avoiding the disadvantage of the traditional method that needs to generate the STL grid model first and then slice it, and saves the processing time. time and memory consumption. In addition, making full use of the topological relationship between the slice line segment and the slice grid quadrilateral, quickly sort the slice line segment to generate the slice outline, and the time complexity is only linear O(n). The method of the invention is stable and reliable, and can efficiently generate a three-dimensional printing slice profile of a three-period minimal curved surface.
附图说明Description of drawings
图1为实施例提供的三周期极小曲面三维打印切片轮廓快速生成方法的流程图;1 is a flowchart of a method for quickly generating a three-period minimal curved surface three-dimensional printing slice profile provided by an embodiment;
图2为实施例提供的生成曲面对应区域的切片四边形网格;Fig. 2 is the sliced quadrilateral mesh of the corresponding area of the generation surface provided by the embodiment;
图3为实施例提供的快速切片结果示意图:(a)为P曲面和四边形网格插值直接生成的切片线段,(b)为切片结果的左视图,(c)为单层切片网格插值计算得到的切片线段;Figure 3 is a schematic diagram of the fast slicing result provided by the embodiment: (a) is the slice line segment directly generated by the interpolation of the P surface and the quadrilateral grid, (b) is the left view of the slicing result, (c) is the single-layer slice grid interpolation calculation the obtained slice segment;
图4为实施例提供的快速切片时间结果;Fig. 4 is the fast slice time result that the embodiment provides;
图5为实施例提供的切片线段排序时间结果:(a)为小数据量下的排序时间结果,(b)为大数据量下的排序时间结果。FIG. 5 shows the sorting time results of slice line segments provided by the embodiment: (a) is the sorting time result under a small data amount, and (b) is the sorting time result under a large data amount.
具体实施方式Detailed ways
为使本发明的目的、技术方案及优点更加清楚明白,以下结合附图及实施例对本发明进行进一步的详细说明。应当理解,此处所描述的具体实施方式仅仅用以解释本发明,并不限定本发明的保护范围。In order to make the objectives, technical solutions and advantages of the present invention clearer, the present invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention, and do not limit the protection scope of the present invention.
图1为实施例提供的三周期极小曲面三维打印切片轮廓快速生成方法的流程图。如图1所示,本实施例提供的方法包括以下步骤:FIG. 1 is a flow chart of a method for quickly generating a three-period minimal curved surface three-dimensional printing slice profile provided by an embodiment. As shown in Figure 1, the method provided by this embodiment includes the following steps:
步骤101:输入待切片的三周期极小曲面的表达式f(x,y,z)=c,切片厚度h,切片四边形网格分辨率n。Step 101: Input the expression f(x, y, z)=c of the three-period minimal surface to be sliced, the slice thickness h, and the slice quadrilateral mesh resolution n.
以三周期极小曲面P曲面为例,函数表达式为f(x,y,z)=cos(0.25πx)+cos(0.25πy)+cos(0.25πz)=0,切片厚度h=0.2mm,网格分辨率n=16,x∈[0,8],y∈[0,8],z∈[0,8]。Taking the three-period minimal surface P surface as an example, the function expression is f(x,y,z)=cos(0.25πx)+cos(0.25πy)+cos(0.25πz)=0, slice thickness h=0.2mm , grid resolution n=16, x∈[0,8], y∈[0,8], z∈[0,8].
步骤102:根据三周期极小曲面的坐标分布范围及切片厚度,生成曲面对应区域的切片四边形网格。Step 102 : According to the coordinate distribution range and slice thickness of the three-period minimal curved surface, generate a sliced quadrilateral grid of the corresponding area of the curved surface.
由于步骤101中确定三周期极小曲面的表达式f(x,y,z)=c时,不仅确定了表达式f(x,y,z)=c的方程式,还确定了每个自变量的取值范围,这样,三周期极小曲面的坐标分布范围就相应确定了,再根据切片厚度,即可获得曲面对应区域。Since the expression f(x,y,z)=c of the three-period minimal surface is determined in step 101, not only the equation of the expression f(x,y,z)=c is determined, but also each independent variable is determined In this way, the coordinate distribution range of the three-period minimal surface is determined accordingly, and then according to the slice thickness, the corresponding area of the surface can be obtained.
如图2所示,根据切片厚度h=0.2mm,分别在zi=i×0.2,(i=1,…,40)的平面上根据切片四边形网格分辨率n=16,在x、y方向分别生成x=j×0.5,(j=0,…,16)、y=j×0.5,(j=0,…,16)的平行线,平行线正交生成曲面对应区域的切片四边形网格。As shown in Figure 2, according to the slice thickness h=0.2mm, on the plane of zi =i×0.2, (i=1,...,40), according to the slice quadrilateral grid resolution n=16, in x, y The directions respectively generate parallel lines of x=j×0.5, (j=0,…,16), y=j×0.5, (j=0,…,16), and the parallel lines are orthogonal to generate the sliced quadrilateral network of the corresponding area of the surface grid.
步骤103:根据三周期极小曲面表达式f(x,y,z)=c,线性插值计算曲面和每层切片四边形网格的切片线段。Step 103 : According to the three-period minimal surface expression f(x, y, z)=c, linearly interpolate the surface and slice line segments of each layer of sliced quadrilateral grids.
具体地,将每层切片四边形网格顶点坐标代入三周期极小曲面函数表达式f(x,y,z)=c中,对于四边形边P1P2,其中两个顶点的三维坐标为P1(x1,y1,z1),P2(x2,y2,z2),利用线性插值方法计算得到切片线段的端点P0:Specifically, the vertex coordinates of each sliced quadrilateral mesh are substituted into the three-period minimal surface function expression f(x, y, z)=c, and for the quadrilateral side P 1 P 2 , the three-dimensional coordinates of the two vertices are P 1 (x 1 , y 1 , z 1 ), P 2 (x 2 , y 2 , z 2 ), use linear interpolation to calculate the endpoint P 0 of the slice line segment:
利用上述方法即可得到曲面和所有切片层四边形网格的切片线段。Using the above method, the slicing line segments of the surface and quadrilateral meshes of all slice layers can be obtained.
如图3(a)即为P曲面和切片四边形网格插值直接生成的切片线段,如图3(b)为切片结果的左视图,如图3(c)为单层切片网格插值计算得到的切片线段。Figure 3(a) is the slice line segment directly generated by the interpolation of the P surface and the sliced quadrilateral grid, Figure 3(b) is the left view of the slice result, and Figure 3(c) is the calculation of the single-layer slice grid interpolation slice line segment.
步骤104:保存切片线段和与该切片线段对应的切片四边形网格中四边形的拓扑关系。Step 104: Save the topological relationship between the slice line segment and the quadrilateral in the slice quadrilateral grid corresponding to the slice line segment.
具体地,建立切片线段数据结构和四边形数据结构,切片线段数据结构保存切片线段的2个顶点信息和与切片线段对应的相交四边形信息,四边形数据结构保存四边形的4个顶点信息和与四边形对应的切片线段信息,以此建立所有切片线段和与该切片线段对应的四边形的对应拓扑关系。Specifically, a slicing line segment data structure and a quadrilateral data structure are established. The slicing line segment data structure preserves 2 vertex information of the slicing line segment and the intersecting quadrilateral information corresponding to the slicing line segment, and the quadrilateral data structure preserves the 4 vertex information of the quadrilateral and the corresponding quadrilateral information. Slice line segment information, thereby establishing the corresponding topological relationship between all slice line segments and the quadrilateral corresponding to the slice line segment.
步骤105:根据切片线段和与该切片线段对应的切片四边形网格中四边形的拓扑关系,对切片线段进行排序。Step 105: Sort the slicing line segments according to the topological relationship between the slicing line segments and the quadrilaterals in the slicing quadrilateral grid corresponding to the slicing line segments.
步骤105的具体步骤如下:The specific steps of step 105 are as follows:
步骤105-1:对于一条未排序的切片线段,找到与该切片线段对应的相交四边形;Step 105-1: For an unsorted slicing line segment, find the intersecting quadrilateral corresponding to the slicing line segment;
步骤105-2:根据该四边形坐标,在四边形网格中找到与该四边形相邻的四边形;Step 105-2: According to the coordinates of the quadrilateral, find the quadrilateral adjacent to the quadrilateral in the quadrilateral grid;
步骤105-3:判断该相邻的四边形中是否存在与该相邻的四边形对应的切片线段;Step 105-3: Determine whether there is a slice line segment corresponding to the adjacent quadrilateral in the adjacent quadrilateral;
步骤105-4:找到和当前切片线段拥有相同坐标的相邻线段;Step 105-4: Find the adjacent line segment with the same coordinates as the current slice line segment;
步骤105-5:重复步骤105-1至步骤105-4即可完成切片线段的排序,有序的切片线段即为最终的切片轮廓。Step 105-5: Repeat steps 105-1 to 105-4 to complete the sorting of slice line segments, and the ordered slice line segments are the final slice outlines.
步骤106:将所有排序后生成的切片轮廓以CLI文件格式输出保存。Step 106: Output and save all the slicing contours generated after sorting in a CLI file format.
本发明的典型实施实例如下:Typical embodiments of the present invention are as follows:
输入待切片的三周期极小曲面P曲面函数表达式为f(x,y,z)=cos(0.25πx)+cos(0.25πy)+cos(0.25πz)=0,x∈[0,8],y∈[0,8],z∈[0,8],切片厚度h=0.2mm,设置不同的网格分辨率n得到不同数目的切片线段,切片线段排序后得到不同精度的切片轮廓,生成层片CLI文件保存。The surface function expression of the input three-period minimal surface P to be sliced is f(x,y,z)=cos(0.25πx)+cos(0.25πy)+cos(0.25πz)=0, x∈[0,8 ], y∈[0,8], z∈[0,8], slice thickness h=0.2mm, set different grid resolutions n to obtain different numbers of slice line segments, and get slice outlines with different precisions after the slice line segments are sorted , and save the generated slice CLI file.
在英特尔至强CPU@3.40GHz,8GB内存的电脑上测试快速切片方法和传统切片方法的切片时间差异。如图4所示,快速切片明显比传统先生成三周期极小曲面STL模型再切片的方法效率更高,同时也节省了保存STL文件的内存消耗。Test the slicing time difference between the fast slicing method and the traditional slicing method on a computer with Intel Xeon CPU@3.40GHz and 8GB memory. As shown in Figure 4, fast slicing is obviously more efficient than the traditional method of first generating a three-period minimal surface STL model and then slicing, and it also saves the memory consumption of saving STL files.
此外,在切片线段排序方面,如图5(a)所示,较小切片线段数据量下快速排序O(n)方法耗时明显少于Kim提出的暴力排序O(n2)方法,快速排序O(n)方法与Lin等人提出的优化排序O(nlogn)方法差异不大;如图5(b)所示,较大切片线段数据量下,快速排序O(n)方法与优化排序O(nlogn)方法的排序耗时在算法效率拐点处基本一致,此后随着切片线段数目的增大,快速排序方法相比O(nlogn)方法会节省越来越多的排序时间。三周期极小曲面结构复杂,一般产生的切片线段数据量较大,本发明方法可以快速对曲面进行切片,进而快速对散乱切片线段排序生成切片轮廓。In addition, in the sorting of slice line segments, as shown in Figure 5(a), the O(n) method of quick sort with a small amount of slice line segment data is significantly less time-consuming than the O(n 2 ) method of brute force sorting proposed by Kim. There is little difference between the O(n) method and the optimized sorting O(nlogn) method proposed by Lin et al. As shown in Figure 5(b), with a large amount of sliced line segment data, the quick sorting O(n) method is different from the optimized sorting O(n) method. The sorting time of the (nlogn) method is basically the same at the inflection point of the algorithm efficiency. After that, as the number of slice line segments increases, the quicksort method will save more and more sorting time compared with the O(nlogn) method. The three-period minimal surface is complex in structure, and generally generates a large amount of slice line segment data. The method of the invention can quickly slice the surface, and then quickly sort the scattered slice line segments to generate slice outlines.
以上所述的具体实施方式对本发明的技术方案和有益效果进行了详细说明,应理解的是以上所述仅为本发明的最优选实施例,并不用于限制本发明,凡在本发明的原则范围内所做的任何修改、补充和等同替换等,均应包含在本发明的保护范围之内。The above-mentioned specific embodiments describe in detail the technical solutions and beneficial effects of the present invention. It should be understood that the above-mentioned embodiments are only the most preferred embodiments of the present invention, and are not intended to limit the present invention. Any modifications, additions and equivalent substitutions made within the scope shall be included within the protection scope of the present invention.
Claims (4)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810040995.2A CN108327287B (en) | 2018-01-16 | 2018-01-16 | A kind of rapid generation of three periods minimal surface 3 D-printing slicing profile |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810040995.2A CN108327287B (en) | 2018-01-16 | 2018-01-16 | A kind of rapid generation of three periods minimal surface 3 D-printing slicing profile |
Publications (2)
Publication Number | Publication Date |
---|---|
CN108327287A CN108327287A (en) | 2018-07-27 |
CN108327287B true CN108327287B (en) | 2019-06-25 |
Family
ID=62925088
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810040995.2A Active CN108327287B (en) | 2018-01-16 | 2018-01-16 | A kind of rapid generation of three periods minimal surface 3 D-printing slicing profile |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108327287B (en) |
Families Citing this family (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109228353B (en) * | 2018-08-06 | 2021-01-12 | 上海大学 | An unsupported 3D printing method with dynamic slicing algorithm |
CN109466065B (en) * | 2018-11-05 | 2019-12-27 | 山东大学 | Support-free non-uniform three-period extremely-small curved surface generation method and system for 3D printing |
CN109622958B (en) * | 2018-12-20 | 2020-06-02 | 华中科技大学 | Method for preparing titanium alloy implant by adopting minimum curved surface porous structure |
CN109977507B (en) * | 2019-03-15 | 2020-10-13 | 浙江大学 | Efficient generation method of porous scaffold with complex morphology |
CN110179570B (en) * | 2019-06-13 | 2021-08-03 | 上海交通大学 | A design method of a gradient porous cervical interbody cage |
CN111062166B (en) * | 2019-12-16 | 2021-10-22 | 浙江大学 | Topological optimization method of three-period minimal surface porous structure based on variable density method |
CN111695259B (en) * | 2020-06-12 | 2024-04-30 | 重庆大学 | Processing method of TPMS structure with continuous gradient wall thickness based on 3D printing |
CN112069730B (en) * | 2020-09-02 | 2024-01-02 | 彭涛 | Three-dimensional curve acquisition method and device for 3D printing |
CN112687253A (en) * | 2020-12-31 | 2021-04-20 | 广州大学 | Light sound insulation structure based on triple-period extremely-small curved surface and preparation method thereof |
CN114228154B (en) * | 2021-11-30 | 2022-10-25 | 西安交通大学 | Modeling slice method and system of gradient void structure based on 3D cross-section features |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105608744A (en) * | 2015-12-24 | 2016-05-25 | 重庆塞拉雷利科技有限公司 | Internal pore design method of simulation periodic minimum surface based on tetrahedral mesh |
CN106200559A (en) * | 2016-07-11 | 2016-12-07 | 湖南大学 | A kind of rapid generation printing section for 3d |
CN106547969A (en) * | 2016-11-02 | 2017-03-29 | 浙江大学 | A kind of 3 D-printing dicing method based on T spline surfaces |
CN106903889A (en) * | 2015-12-21 | 2017-06-30 | 姜海涛 | A kind of rapid section algorithm of STL models |
CN107145682A (en) * | 2017-06-01 | 2017-09-08 | 浙江大学 | Design method of three-period minimal surface porous scaffold based on T-spline entity |
-
2018
- 2018-01-16 CN CN201810040995.2A patent/CN108327287B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106903889A (en) * | 2015-12-21 | 2017-06-30 | 姜海涛 | A kind of rapid section algorithm of STL models |
CN105608744A (en) * | 2015-12-24 | 2016-05-25 | 重庆塞拉雷利科技有限公司 | Internal pore design method of simulation periodic minimum surface based on tetrahedral mesh |
CN106200559A (en) * | 2016-07-11 | 2016-12-07 | 湖南大学 | A kind of rapid generation printing section for 3d |
CN106547969A (en) * | 2016-11-02 | 2017-03-29 | 浙江大学 | A kind of 3 D-printing dicing method based on T spline surfaces |
CN107145682A (en) * | 2017-06-01 | 2017-09-08 | 浙江大学 | Design method of three-period minimal surface porous scaffold based on T-spline entity |
Also Published As
Publication number | Publication date |
---|---|
CN108327287A (en) | 2018-07-27 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108327287B (en) | A kind of rapid generation of three periods minimal surface 3 D-printing slicing profile | |
CN107767457B (en) | STL digital-analog generating method based on point cloud rapid reconstruction | |
CN106373184B (en) | A kind of 3 D-printing model puts required amount of support Method of fast estimating | |
CN106547969B (en) | A kind of 3 D-printing dicing method based on T spline surface | |
CN102508973B (en) | Rapid intersection method for STL (stereo lithography) models of products | |
CN105045205B (en) | A kind of cutter spacing path generating method and its digital-control processing system based on triangle gridding bias compensation | |
CN101672637A (en) | Digitizing detection method of complicated curved face | |
CN106354098B (en) | A Method for Generating Tool Machining Trajectories on NURBS Composite Surfaces | |
CN103970949B (en) | A kind of rapid shaping intermediate cam patch model by side layered approach | |
CN106200559A (en) | A kind of rapid generation printing section for 3d | |
CN101515168B (en) | Method for generating ring-cutting roughing NC tool path of product triangular mesh model | |
CN106903889A (en) | A kind of rapid section algorithm of STL models | |
CN110188423A (en) | A kind of linear engineering structure fast B IM modeling method based on FEM meshing | |
CN101510086A (en) | Multi-shaft numerical control machining knife rail generating method for product triangle grid model | |
CN109325316B (en) | Efficient Parallel Slicing Method for STL Model Based on Common Point Welding Sorting | |
CN101403909B (en) | NC tool path generation method for triangular mesh subdivision surface | |
CN111710022B (en) | Rapid forming slice processing method for avoiding contour intersection | |
CN108320327B (en) | Three-cycle extremely-small-curved-surface equal-wall-thickness layered filling area generation method | |
CN103480534B (en) | Control During Paint Spraying by Robot curve surface of workpiece formative method | |
CN109551768A (en) | A kind of data processing method of the 3D printing file based on STL | |
CN201514207U (en) | A digital detection system for complex curved surfaces | |
CN110356008B (en) | Hash table-based method for quickly splicing scattered line segments | |
CN104821014B (en) | Merge the three-dimensional process model building method of tool radius | |
CN115047825A (en) | Method for displaying numerical control machining milling in real time | |
Tian et al. | Research on fast grouping slice algorithm for STL model in rapid prototyping |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |