Main Content

intersect

Boolean intersection operation on two RF PCB shapes

Description

example

c = intersect(shape1,shape2) intersects shape1 and shape2 using the intersect operation. You can also use the & to intersect the two shapes.

Examples

collapse all

Create and display an annular ring.

shape1 = ringAnnular(InnerRadius=1e-3);
show(shape1)

Figure contains an axes object. The axes object contains 2 objects of type patch. This object represents PEC.

Create and display a square ring.

shape2 = ringSquare(InnerSide=1e-3);
show(shape2)

Figure contains an axes object. The axes object contains 2 objects of type patch. This object represents PEC.

Find and display the intersection of the shapes.

shapeIntersection = intersect(shape1,shape2);
show(shapeIntersection)

Figure contains an axes object. The axes object contains 2 objects of type patch. This object represents PEC.

Create and display an annular ring.

shape1 = ringAnnular(InnerRadius=1e-3);
show(shape1)

Figure contains an axes object. The axes object contains 2 objects of type patch. This object represents PEC.

Create and display a square ring.

shape2 = ringSquare(InnerSide=2e-3,Width=4e-3);
show(shape2)

Figure contains an axes object. The axes object contains 2 objects of type patch. This object represents PEC.

Display the intersection of the shapes.

shapeIntersection = shape1 & shape2;
show(shapeIntersection)

Figure contains an axes object. The axes object contains 2 objects of type patch. This object represents PEC.

Input Arguments

collapse all

First shape created using custom elements and shape objects of RF PCB Toolbox™, specified as an object.

Example: shape1 = bendCurved; specifies the first shape as a bendCurved object.

Second shape created using custom elements and shape objects of RF PCB Toolbox, specified as an object.

Example: shape2 = ringAnnular; specifies the second shape as a ringAnnular object.

Introduced in R2021b