Model.surfacestringscreatemidline#

Model.surfacestringscreatemidline(surface_collection, alonglines_collection=Collection(), midlines_output_collection=s_defaultCollection)#

Creates midlines for strings of narrow surfaces (fillets, rib tops, etc…). The function takes as input a collection of surfaces that can be interpreted as narrow string sets (one or several disconnected strings).

Optionally, the configuration of string could be additionally supported with given collection of the along sides lines. The created midlines could be output to the given output collection.

Parameters:
  • surface_collection (Collection) – The input collection containing the narrows surfaces.

  • alonglines_collection (Collection) – The collection containing the along side lines.

  • midlines_output_collection (Collection) – The collection to which the created midlines will be output.

Example#

Create midlines for surfaces 7054-7077, with the long side lines auto-identified, and without placing the created midlines in an output collection#
import hm
import hm.entities as ent

model = hm.Model()

surface_col = hm.Collection(model, ent.Surface, list(range(7054, 7078)))

model.surfacestringscreatemidline(surface_collection=surface_col)
Create midlines for surfaces 7054-7077, with the long side lines auto-identified, and placing the created midlines in an output collection#
import hm
import hm.entities as ent

model = hm.Model()

surface_col = hm.Collection(model, ent.Surface, list(range(7054, 7078)))

midlines_output_col = hm.Collection(model, ent.Line, populate=False)

model.surfacestringscreatemidline(
    surface_collection=surface_col,
    midlines_output_collection=midlines_output_col
)