1 # CEA/LGLS 2004-2005, Francis KLOSS (OCC)
2 # =======================================
11 # A small cube centered and put on a great cube build with partition
30 v_1 = MakeVertex(g_ox , g_oy , g_oz )
31 v_2 = MakeVertex(g_ox+v_arete3, g_oy+g_arete , g_oz+v_arete3)
33 v_3 = MakeVertex(g_ox+g_arete , g_oy+g_arete , g_oz+g_arete )
34 v_4 = MakeVertex(g_ox+v_arete2, g_oy+v_arete2, g_oz+v_arete2)
39 s_base = MakeBoxTwoPnt(v_1, v_2)
40 s_haut = MakeBoxTwoPnt(v_3, v_4)
45 p_dir1 = MakeVectorDXDYDZ(1, 0, 0)
46 p_dir2 = MakeVectorDXDYDZ(0, 0, 1)
47 p_dir3 = MakeVectorDXDYDZ(0, 1, 0)
51 p_tools.append(MakePlane(v_3, p_dir1, g_trim))
52 p_tools.append(MakePlane(v_4, p_dir1, g_trim))
53 p_tools.append(MakePlane(v_3, p_dir2, g_trim))
54 p_tools.append(MakePlane(v_4, p_dir2, g_trim))
55 p_tools.append(MakePlane(v_3, p_dir3, g_trim))
57 piece = MakePartition([s_base, s_haut], p_tools, [], [], ShapeType["SOLID"])
62 piece_id = addToStudy(piece, "ex03_cube2partition")
67 # Create hexahedrical mesh on piece
68 # ---------------------------------
70 hexa = smesh.Mesh(piece, "ex03_cube2partition:hexa")
73 algo.NumberOfSegments(5)