create_sphere#

Modeler3D.create_sphere(position, radius, name=None, matname=None)[source]#

Create a sphere.

Parameters:
positionlist

List of [x, y, z] coordinates for the center position of the sphere.

radiusfloat

Radius of the sphere.

namestr, optional

Name of the sphere. The default is None, in which case the default name is assigned.

matnamestr, optional

Name of the material. The default is None, in which case the default material is assigned.

Returns:
pyaedt.modeler.cad.object3d.Object3d

3D object.

References

>>> oEditor.CreateSphere

Examples

>>> from pyaedt import Hfss
>>> aedtapp = Hfss()
>>> ret_object = aedtapp.modeler.create_sphere(position=[0,0,0], radius=2,
...                                            name="mysphere", matname="copper")