Circle
Create a circle or disk in 2D.
Syntax
model.component(<ctag>).geom(<tag>).create(<ftag>,"Circle");
model.component(<ctag>).geom(<tag>).feature(<ftag>).set(property,<value>);
model.component(<ctag>).geom(<tag>).feature(<ftag>).getType(property);
Description
Use model.component(<ctag>).geom(<tag>).create(<ftag>,"Circle") to create a disk in 2D. The following properties are available:
corner | center
Positions the object either centered about pos or with the lower-left corner of a surrounding box in pos
solid | curve
on | off
all | obj | dom | bnd | 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.
Compatibility
model.component(<ctag>).geom(<tag>).create(<ftag>,"circ2") creates a solid disk.
model.component(<ctag>).geom(<tag>).create(<ftag>,"circ1") creates a circle curve.
The following properties are also available:
x, y
The property const is no longer available.
Example
The sequence below creates a unit disk (solid circle object).
Code for Use with Java
Model model = ModelUtil.create("Model1");
model.component().create("comp1");
GeomSequence g = model.component("comp1").geom().create("geom1",2);
g.create("c1","Circle");
g.feature("c1").set("pos",new double[]{2,3});
String base = g.feature("c1").getString("base");
g.run();
Code for Use with MATLAB
model = ModelUtil.create('Model1');
model.component.create('comp1');
g = model.component('comp1').geom.create('geom1',2);
g.create('c1','Circle');
g.feature('c1').set('pos',[2,3]);
base = g.feature('c1').getString('base');
g.run;
See Also
Ellipse