basic computational geometry