Partition
Partition geometry objects using tool objects or a work plane.
Syntax
model.component(<ctag>).geom(<tag>).create(<ftag>,"Partition");
model.component(<ctag>).geom(<tag>).feature().selection(property);
model.component(<ctag>).geom(<tag>).feature().set(property,<value>);
model.component(<ctag>).geom(<tag>).feature().getType(property);
Description
The Partition Boolean operation partitions each input object using a set of tool objects or a work plane. That is, within the input object new boundaries, edges, and vertices are created that come from the tools or the work plane.
The following properties are available:
...geom(<tag>).
absRepairTol()
on | off
objects | workplane
...geom(<tag>).
repairTol()
auto | relative | absolute
...geom(<tag>).
repairTolType()
on | off
all | obj | dom | bnd | edg | pnt | off
Show selections, if selresult is on, in physics, materials, and so on; in part instances; or in 3D from a plane geometry. obj is not available in a component’s geometry. dom, bnd, and edg are not available in all features.
For information about the selresult and contributeto properties, see Selections of Geometric Entities.
Example
Create an interior boundary in a cylinder by partitioning it with an oblique work plane:
Code for Use with Java
Model model = ModelUtil.create("Model");
model.component().create("comp1");
GeomSequence g = model.component("comp1").geom().create("geom1", 3);
g.create("cyl1", "Cylinder");
g.feature("cyl1").set("h", 10);
g.create("wp1", "WorkPlane");
g.feature("wp1").set("planetype", "general");
g.feature("wp1").setIndex("genpoints", 4, 0, 2);
g.feature("wp1").setIndex("genpoints", 5, 1, 2);
g.feature("wp1").setIndex("genpoints", 5, 2, 2);
g.create("par1", "Partition");
g.feature("par1").selection("input").set("cyl1");
g.feature("par1").set("partitionwith", "workplane");
g.run("par1");
Code for Use with MATLAB
model = ModelUtil.create('Model');
model.component.create('comp1');
g = model.component('comp1').geom.create('geom', 3);
g.create('cyl1', 'Cylinder');
g.feature('cyl1').set('h', 10);
g.create('wp1', 'WorkPlane');
g.feature('wp1').set('planetype', 'general');
g.feature('wp1').setIndex('genpoints', 4, 0, 2);
g.feature('wp1').setIndex('genpoints', 5, 1, 2);
g.feature('wp1').setIndex('genpoints', 5, 2, 2);
g.create('par1', 'Partition');
g.feature('par1').selection('input').set('cyl1');
g.feature('par1').set('partitionwith', 'workplane');
g.run('par1');
See Also
Compose, Union, Intersection, Difference, WorkPlane, PartitionDomains, PartitionEdges