Skip to main content
1 of 5

Drawing a graph with vertex avoiding edges?

I'd like to draw something like the following graph:

testGraph = Graph[{1 \[UndirectedEdge] 2, 1 \[UndirectedEdge] 4, 2 \[UndirectedEdge] 3, 2 \[UndirectedEdge] 5, 3 \[UndirectedEdge] 4}, VertexLabels -> {1 -> "1", 2 -> "2", 3 -> "3", 4 -> "4", 5 -> "5"}, VertexCoordinates -> {{0, 0}, {1, 1}, {2, 3}, {4, 1}, {3, 3}}, ImagePadding -> 10] 

However, without changing any of the explicitly specified vertex positions, I'd like edges to curve to avoid vertices. For example, while it's fine that the edges between vertices 1 and 5, 2 and 5, and 3 and 4 cross, it's no good that the edge between vertices 1 and 5 passes through a small sphere around vertex 2.

Is there any way to avoid this in Mathematica v9? This is a dream, however, could I specify a length for an edge and have it travel along an arc to meet that length requirement provided stationary vertices?