| Download
All published worksheets from http://sagenb.org
Project: sagenb.org published worksheets
Views: 168733Image: ubuntu2004
Here are some functions which compute the dual of a planar graph. Currently, I don't think there is any error checking, and I don't remember if I decided that this implementation was correct or not. However, the dual computed in the example below is correct. I think that it works.
[[0, 5, 2], [0, 4, 3], [0, 2, 4], [0, 3, 5], [1, 4, 2], [1, 5, 3], [1, 3, 4], [1, 2, 5]]