Model.solidmap_end#

Model.solidmap_end(options, density_or_size, bias_style, biasing, elemDest_old)#

Indicates the end of a solid mapping function block that executes the solid mapping algorithm to. It must be paired with a Model.solidmap_begin() function. A single solidmap mesh is a result of the block of functions.

In a solidmap function block, all of the commands before Model.solidmap_end() are for preparing input data. Model.solidmap_end() is the function that actually performs the solid mapping.

Parameters:
  • options (int) – Flags that indicate different modes for solid mapping. It is not recommended to manually set these bits. Instead, use them from an existing function file.

  • density_or_size (double) – Either the element density or size in the along direction, depending on options in the options parameter.

  • bias_style (int) –

    The type of biasing to use. Valid values are:

    0 - Linear

    1 - Exponential

    2 - Bell curve

  • biasing (double) – The biasing intensity value. A value of 0 indicates no biasing.

  • elemDest_old (int) – The legacy element destination option. Recommended value is 0.

Example#

For a solidmap using the following inputs: source geometry - lines with IDs 73 and 51; destination geometry - lines with IDs 32 and 41; along geometry - lines with IDs 74 and 75, surfaces with IDs 100 and 95, nodes with IDs 80 and 101-105; element size - 10.0.#
import hm
import hm.entities as ent

model = hm.Model()

model.solidmap_begin(ordered=1)
model.solidmap_prepare_usrdataptr(type="SOURCE", options=10)
source_line_collection = hm.Collection(model, ent.Line, [73, 51])
model.solid_prepare_entitylst(entity_type=ent.Line, reserved=0)

model.solidmap_prepare_usrdataptr(type="DEST", options=2)
dest_line_collection = hm.Collection(model, ent.Line, [32, 41])
model.solid_prepare_entitylst(entity_type=ent.Line, reserved=0)

model.solidmap_prepare_usrdataptr(type="ALONG", options=7)
along_line_collection = hm.Collection(model, ent.Line, [74, 75])
model.solid_prepare_entitylst(entity_type=ent.Line, reserved=0)

surfaces_collection = hm.Collection(model, ent.Surface, [100, 95])
model.solid_prepare_entitylst(entity_type=ent.Surface, reserved=0)

node_list = [ ent.Node(model, id) for id in [80, 101, 102, 103, 104, 105] ]

model.solid_prepare_nodeline(start=0)

model.solidmap_end(
    options=0,
    density_or_size=10.0,
    bias_style=0,
    biasing=0,
    elemDest_old=0
)