Loading...
Implement a conversion between Cartesian coordinates and homogeneous coordinates, a fundamental concept in projective geometry. This conversion is crucial in computer vision for representing and applying projective transformations.
In Cartesian coordinates, a 2D point is represented as (x,y). In contrast, homogeneous coordinates introduce an additional dimension, representing the same point as (x,y,1). This extension enables the use of linear algebra techniques, such as matrix multiplications, to perform projective transformations.
Here are the steps to convert between these coordinate systems:
This technique is widely used in image processing and computer vision applications.
to_cartesian([6, 8, 2])
[3.0, 4.0]
6/2 = 3, 8/2 = 4