Partition by Expression
Use Partition by Expression () to partition geometric entities of a mesh by creating at least one new geometric entity for the elements that fulfill the specified logical expression, as shown in Figure 8-92.
Figure 8-92: An imported mesh with hexahedral, tetrahedral, and prism elements in one single domain (left). Using a Partition by Expression with the Logical expression ishex to define one domain for the hexahedral elements and one domain for the rest (right).
To add a Partition by Expression node, select one or several entities in the Graphics window, then choose one of the following:
Right-click in the Graphics window to open The Graphics Context Menu. Select Partition by Expression () from the Booleans and Partitions menu.
Click Booleans and Partitions () on The Mesh Toolbar and select Partition by Expression.
Right-click the Mesh node and select Partition by Expression () from the Booleans and Partitions menu.
Enter the properties for Partition by Expression using the following sections:
Then use the sections below to specify the geometric entities to partition, the logical expression, and the condition for division.
Geometric Entity Selection
Define the geometric entities that you want to partition. You choose the geometric entity level from the Geometric entity level list:
Choose Entire geometry to divide all geometric entities according to the specified cylinder.
Choose Domain, Boundary, or Edge to specify the domains, boundaries, or edges, respectively, that you want to partition or choose a named selection to refer to a previously defined selection. Use All domains, All boundaries, or All edges to select all entities of the specified dimension.
Expression
Enter a logical expression using x, y, or z (3D only); the mesh size h and mesh quality qual* (see Mesh Element Quality); Unary, Binary, and List Operators and Their Precedence Rules; and Mathematical and Numerical Constants in the Logical expression field. For instance, the expression (x*x+y*y)<1 defines a ball partition in 2D and an infinite cylinder division in 3D. You can also use the Boolean variables istri, isquad, istet, ispyr, isprism, or ishex in the expression in order to partition the mesh according to the respective element type (triangular, quadrilateral, tetrahedral, pyramid, prism, or hexahedral, respectively). For instance, the expression istet makes a separate domain for each connected set of tetrahedra, while the expression ispyr || ishex makes a separate domain for each connected set of elements containing pyramids or hexahedra. You can also use the meshelement variable to partition the mesh. For example, if you know that elements 1 to 10 are a separate domain, write meshelement<=10 to partition this as a separate domain.
Condition
Use the Include element if expression is fulfilled for list to select the condition for which the logical expression is fulfilled for an element. Choose All vertices to make an element satisfy the expression if it is true for all element vertices, or choose Some vertex if it is true for at least one element vertex.