Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Short lines create longer lines- algorithm

Posted on 2011-03-07
2
Medium Priority
?
354 Views
Last Modified: 2012-05-11
Hello experts!


I have a set of short (2D) lines (described by their border points).

1. Some of these lines visually create longer lines (please have a look at the image)

2. These longer lines create geometrical figures


Question:

Can you think about any smart algorithm to detect lines created by short lines and then to detect geometrical figures?


Thank you

panJames




 lines lines
0
Comment
Question by:panJames
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 27

Accepted Solution

by:
d-glitch earned 1000 total points
ID: 35056097
Sure.  Starting is easy, but making it smart may be hard.

All of your short line segments are characterized by a pair of endpoints and a slope.

You can combine short line segments into longer line segments if the slopes match
to some TBD tolerance and one endpoint of each segment are close enough.
That's another TBD.

Once you 're done with the line segments, you can start looking for corners, and
then polygons.  Look for endpoints that are close enough.

Polygon extraction is one of the standard image processing algorithms.
0
 
LVL 6

Assisted Solution

by:t-max
t-max earned 1000 total points
ID: 35056277
This is a hard problem and can't be easily solved. It's similar to make a program to solve captchas.
Moreover, the draw you attached is a 2D but seems to be in perspective, which makes things even harder (a square is a trapezoid, a circle turns to ellipse, etc).
If your problem isn't constrained by some pre-defined assumptions, I'm not sure you'll find an algorithm to solve this, no matter how "smart" it is.
0

Featured Post

How to Use the Help Bell

Need to boost the visibility of your question for solutions? Use the Experts Exchange Help Bell to confirm priority levels and contact subject-matter experts for question attention.  Check out this how-to article for more information.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

One of Google's most recent algorithm changes affecting local searches is entitled "The Pigeon Update." This update has dramatically enhanced search inquires for the keyword "Yelp." Google searches with the word "Yelp" included will now yield Yelp a…
Article by: Nadia
Linear search (searching each index in an array one by one) works almost everywhere but it is not optimal in many cases. Let's assume, we have a book which has 42949672960 pages. We also have a table of contents. Now we want to read the content on p…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …
Suggested Courses

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question