Jump to content

CS Grammar


mje

Recommended Posts

Hi Gang,

I need some help with some computer science grammar.

Say I have a 2D surface and an array of rectangles in that geometry. For an arbitrary coordinate I need to determine which rectangle, if any, contains the coordinate.

I have a simple solution that just tackles it via brute force, and it works just fine because I typically don't have to track more than a thousand features.

However I think this is a good learning experience. I imagine how one can do much better than iterating over each element by building a branching data structure and stepping through the hierarchy. I know this is a common problem in math and CS but I have no idea what this is called, so I'm not having much luck with blind searching. Does anyone at least know the name of what it is I'm trying to do?

Link to comment

Thanks Phillip! That quadtree is pretty much what I imagined in a 2D space. New words are fun!

What I'm really after I imagine is simply extending a binary search into N-dimensions, but the fact that's I'm dealing with areas, volumes, or N-dimensional volumes does add a slight kink. That seems like a good start.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.