still need to fix some minor bugs and have only two similar values for
each rectangle