An algebraic approach to Hough transform