NODE_IDS_CLOSEST_TO

Returns array containing node IDs (integers) of the number (num) of
nodes on a flexible body closest to a specified marker.

Format

node_ids_closest_to (marker, flex_body, num, intpt)

Arguments

 
marker
Name of the marker object.
flex_body
Name of the flexible body object.
num
Number of nodes requested.
intpt
Integer flag:
1 - Consider only interface nodes.
0 - Consider all nodes.

Returns

If NODES_IDS_CLOSEST_TO finds no nodes, it returns a single
integer value of -1 with no warning.

Example

The following example displays the three nodes on the flexible body
named link closest to marker_1 on ground. It displays the nodes in the
Info window, as shown in the figure below.
var set var=.nodes int=(eval(node_ids_closest_to(marker_1, link, 3, 0))) &
comments = "3 closest nodes to marker"