hm_getdistancefromnearestsurface

Gets the distance of the given point from the nearest of the surfaces with IDs specified as arguments.

Syntax

hm_getdistancefromnearestsurface point_xyz surf_id_list

Type

HyperMesh Tcl Query Command

Description

Gets the distance of the given point from the nearest of the surfaces with IDs specified as arguments.

Inputs

point_xyz
The list of x, y, z coordinates of the point.
surf_id_list
List of surface IDs.

Examples

The function returns a list consisting of two values. The first value is the distance to the closest surface. The second value is ID of the closest surface.

To get closest to the point with coordinates (10, 20, 30) point on the surface with ID 13:

hm_getdistancefromnearestsurface [list 10 20 30] 13

To get closest surface from the set with IDs 13 14 15:

hm_getdistancefromnearestsurface [list 10 20 30] [list 13 14 15]

To get closest to the point with ID 2 point on the surface with ID 13:

hm_getdistancefromnearestsurface [hm_getvalue points id=2 dataname=coordinates] 13

Errors

None.