Jump to content
Mounika.Chengalva

Find nearest surface

Recommended Posts

Hi,

I m checking for a command to select an surface nearest to the selected surface. Anybody can help me plz.

 

Basically i have a solid and surface imported from catia (Surface is overlapping on solid). now in hypermesh i want to know the project the surface mesh to solid surface (solid surface - which on it is overlapping).

any help plz.

Share this post


Link to post
Share on other sites

Hello,

 

You can try to identify overlapping surfaces by the following tool: "Geometry->Check->Surfaces->Interference"

 

Now follow this:

  • Select surfaces of the single surface and the solid (e.g. select one solid surface, extend it by attached) for "surfaces"
  • Switch "Isolate only failure" to None
  • Switch "Save failed" to Surfaces
  • Press Run

Now the intersecting surfaces are saved und you can retrieve it by any surface command, e.g. mask->surfs->retrieve (see picture)

 

Best Regards,

Mario

 

image.thumb.png.e6f4dc70488f5814fb16d61eaae7abc4.png

Share this post


Link to post
Share on other sites

Hi all, i think i'm not very clear with my problem. here are few pictures which will display my issue i hope.

 

image.png.3ea21fb7091682c20a9bee500a831af2.pngimage.png.62e8bfdddf7295c90ecdd181f1ea9be9.png 

 

The free surface over here is meshed and now i want to project the elements to the solidbody-picture3 (corresponding face/surface) for that i need to know the surface_ID for using the following command.

*markprojecttosurface entities mark vector surface

 

Share this post


Link to post
Share on other sites

Hi @Mounika.Chengalva 

try the following command, it will return the distance to nearest surface as well as the id of nearest surface. 

You need to provide all surface ids of the solid as a list.

 

image.png.0de6024fa04abee58bc351677ef47990.png

Share this post


Link to post
Share on other sites
16 hours ago, Mounika.Chengalva said:

Hi all, i think i'm not very clear with my problem. here are few pictures which will display my issue i hope.

 

image.png.3ea21fb7091682c20a9bee500a831af2.pngimage.png.62e8bfdddf7295c90ecdd181f1ea9be9.png 

 

The free surface over here is meshed and now i want to project the elements to the solidbody-picture3 (corresponding face/surface) for that i need to know the surface_ID for using the following command.

*markprojecttosurface entities mark vector surface

 

Hi 

To get surface ID you can use Tools=>find=>surface with number ticked ON. This would give you the surface ID's.

Share this post


Link to post
Share on other sites

Hi, if you want to get the solid surface by tcl command, try this

#find center of the free surface:

lassign [join [hm_getgeometrybox surfs $FreeSurfID]] x1 y1 z1 x2 y2 z2

set centerx [expr ($x1+$x2)/2]

set centery [expr ($y1+$y2)/2]

set centerz [expr ($z1+$z2)/2]

#now find the surface that closest to above center:

*createmark surfs 1 all

hm_markremove surfs 1 $FreeSurfID; #we don't want to find the free surface anymore

lassign [hm_measureshortestdistance2 $centerx $centery $centerz surfs 1 0 0] =>  =>  =>  => ClosestSurfID

puts $ClosestSurfID

 

;)

 

 

 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×