Model.features_add#

Model.features_add(node_list, lines, smooth)#

Creates elements or lines between a list of nodes.

Parameters:
  • node_list (EntityList) – The list of desired node entities.

  • lines (int) –

    0 - Create plot elements connecting the nodes in the list. These elements are created in the component named ^open features. Next, elements in the ^open features component that create closed chains (loops) of elements are moved to a component named ^feature.

    1 - Creates a line in the “^feature” component.

  • smooth (int) –

    0 - Do not smooth the lines.

    1 - Smooth the line created through the nodes of the feature.

Example#

Create a smooth line between the nodes in node_list#
import hm
import hm.entities as ent

model = hm.Model()

model.features_add(
  node_list=[ent.Node(model, i) for i in range(1,11)],
  lines=1,
  smooth=1
)