mesh_add_feature
Creates a specified COMSOL mesh feature—such as FreeTet, Sweep, Size, or Refine—with properties, selections, and parent settings to support custom meshing workflows.
Instructions
Create a mesh feature of any COMSOL type (generic escape hatch).
Valid types come from catalog_mesh_features (e.g. FreeTet, FreeTri,
Map, Sweep, BndLayer, Size, SizeExpression, Distribution, Refine, Import,
CopyFace, CornerRefinement, Vertex, ...).
Args:
feature_type: COMSOL mesh feature type, e.g. "FreeTet".
mesh: mesh sequence tag (None = first).
tag: feature tag (None = auto from the type, e.g. "ftet1").
properties: feature properties, e.g. {"method": "delaunay"}.
Property names must match COMSOL's; use mesh_features to read the
available names of existing features.
selection: geometric entity numbers to select.
named: named selection tag to select instead.
all_entities: select all entities of entity_dim.
entity_dim: selection dimension (3=domains, 2=boundaries, 1=edges,
0=points). Default depends on the feature type (FreeTet=domains,
FreeTri/Map=boundaries in 3D, BndLayerProp=boundaries).
parent: parent feature tag for child features (e.g. BndLayerProp under
a BndLayer, CornerProp under CornerRefinement).
component: component tag (None = auto-detect).
model: model name/tag (None = current model).
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"feature_type": "<feature_type>"
},
"name": "mesh_add_feature"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| tag | No | ||
| mesh | No | ||
| model | No | ||
| named | No | ||
| parent | No | ||
| component | No | ||
| selection | No | ||
| entity_dim | No | ||
| properties | No | ||
| all_entities | No | ||
| feature_type | Yes |