Model.createcirclefromcenterradius#

Model.createcirclefromcenterradius(entitylist, vector, radius, angle, offset)#

Creates a circle or arc given the center and radius.

Parameters:
  • entitylist (EntityList) – A list containing the node entity objects to be used as center points. A circle or arc is created for each node in the list.

  • vector (hwTriple) – The hwTriple object defining the vector components. User can also supply a Python list of three doubles.

  • radius (double) – The radius of the circle or arc.

  • angle (double) – The angle of the arc. To create a circle, set to 360.

  • offset (double) – Sets the starting offset for an arc.

Example#

Create a circle centered at node with ID 18, with radius 3.0, and in the plane whose normal is defined by (0.0, 0.0, 1.0)#
import hm
import hm.entities as ent

model = hm.Model()

model.createcirclefromcenterradius(
    entitylist=[ent.Node(model, 18)],
    vector=[0.0, 0.0, 1.0],
    radius=3.0,
    angle=360.0,
    offset=0.0,
)