implement a skeleton-based rectangle matching on a single plane. To solve the "H" and "L" shape problem