Building geometry or structures is very important in COMSOL as the simulation entirely depends on the structure. But there are only a few options like circle, square, rectangle, polygon, etc. that COMSOL provides. What to do if our structure is something more than the basic blocks? Here comes the Boolean and Partition operations to modify the structures.
** We will be using 2D models and only the functions will be described. For better understanding please watch the video at the end of the article**
What is Boolean?
Most of us may know about boolean algebra. It has only two variables; True/False, 0/1, Yes/No, etc. We can apply the same operations in case of structures. But eventually, you will find that, instead of Boolean, they more relate to Set operations. In COMSOL, the operations are named as;
◉ Union: This operation is like 'addition' process. We can turn multiple different domains into a single one using a union. Here, if we wish, we can leave the intersected boundary edges as it was or we can remove the edges.
◉ Intersection: We can keep the intercepted area of the domains by this operation.
◉ Difference: It is the 'subtraction' operation. It gives two selection window. One is for the domains to be added and the other is for the subtracted domains. The subtracted domains along with the intercepted portions with the added domains will disappear from the structure.
◉ Composition: Now composition allows us to make customized geometry. We just need to select the domains and make an equation, a boolean equation, that serves our purpose.
Partition:
Partition basically tends to make parts inside the domains or objects. Now parts can be created inside the object body or on the edges.
◉ Object Body: To make the parts inside the body, we either need another object to specify the part or some lines to separate the parts. To create parts with the help of another object, we need to go for the 'partitions objects' option and select the object to partition and the tool object.
Again if we want to partition the domains, we need to choose some vertices that will draw some lines and will create the partitions. For this, we need to choose the 'partition domains' and select the necessary parameters.
◉ Edge Partition: This will part the selected edges according to the given ration. We just need to choose the edges here and fix the ration. This will create two separate partitioned edges from a single one.
Check out the video below to have better visualization: Boolean operations & Partitions
Image Source:
* COMSOL Multiphysics
* Stack Overflow
0 comments: