DifferenceΒΆ

Learning targets

  • Use Boolean operation to form the difference of two objects

This example forms the difference of two circles by means of the Boolean difference operator.

_images/ex2d_difference_mesh.png

.jcm Input File

  • layout.jcm [ASCII]

     1Layout2D {  
     2  UnitOfLength = 1  
     3  Objects {
     4    
     5    Parallelogram {
     6      Priority = ComputationalDomain
     7      DomainId = 1
     8      BoundingBox {
     9        Offset = [1 1 1 1]
    10      }
    11    }
    12    
    13    BooleanOperation {
    14      DomainId = 2 
    15      Operator = Difference
    16      A { 
    17        Circle {
    18          Radius = 6
    19          GlobalPosition = [-4.0 0.0]
    20          RefineAll = 2
    21        }
    22      }
    23      
    24      B {
    25        Circle {
    26          Radius = 4
    27          GlobalPosition = [1.75 0.0]
    28          RefineAll = 2
    29        }
    30      }
    31    }
    32  }  
    33  
    34}