We’re updating our badges platform. Badge issuance is temporarily paused, but all completions are being recorded and will be fulfilled once the platform is live. Thank you for your patience.
Preprocessing

Preprocessing

Topics related to geometry, meshing, and CAD.

CX_Find_Cell_With_Point vs CX_Find_Closest_Cell_To_Point?

    • Ivan Mendez
      Subscriber
      Hey all, I have a csv that contains the x,y,z coordinates of points on my geometry. I found that I can find the cell that contains that point using CX_Find_Cell_With_Point. However, I also found CX_Find_Closest_Cell_To_Point in the cxndsearch.h header. What are the differences between the two, and what does "double *dist" mean in the CX_Find_Closest_Cell_To_Point argument?
       
      FLUENT_EXPORT CX_Cell_Id *CX_Find_Cell_With_Point(ND_Search *, double v[3], double time);
      FLUENT_EXPORT CX_Cell_Id *CX_Find_Closest_Cell_To_Point(ND_Search *, double v[3], double *dist, double eps);
    • Rob
      Forum Moderator

      As a guess (I'm not allowed to comment on macros that aren't in the UDF manual) the macros will return the cell if the point is in it, the Closest macro will do some checks incase you've missed the meshed domain. 

      In C coding "double" calls double precision, ie more significant figures are stored. If a mesh is very fine or the cells small a distance might return zero without the extra accuracy. 

Viewing 1 reply thread
  • The topic ‘CX_Find_Cell_With_Point vs CX_Find_Closest_Cell_To_Point?’ is closed to new replies.