# Drawing a directed graph

• Apr 14th 2008, 06:39 AM
Eclyps19
Drawing a directed graph
Now, I understand how directed graphs work. But drawing one for this problem just baffles me.

I have a 3 gallon and a 5 gallon jug. I can fill them from a tap, transfer water from one another, and empty them. I need to prove that I can get exactly 1 gallon in one jug. I then need to draw the process using a directed graph model.

I solved the first part. I eventually got the 3 gallon jug with exactly one gallon of water. I'm having trouble trying to figure out how to draw this though. A hint says to use (a,b) to show each jug. I'm at a complete loss of how to do this without having a vertex representing every step, but this would just create a line. Any ideas?
• Apr 14th 2008, 07:48 AM
Plato
$\displaystyle (0,5) \to (3,2) \to (0,2) \to (2,0) \to (2,5) \to (3,4) \to (0,4) \to (3,1)$
• Apr 14th 2008, 07:50 AM
Eclyps19
wow, so I guess I was right?

it just seems... too simple... why draw a graph in the first place?

ah well, I appreciate it.
• Apr 14th 2008, 08:38 AM
awkward
You might also try plotting the points (0,5) etc. on an ordinary Cartesian x-y graph and then draw arrows connecting them. This reveals a certain structure to the solution which may not otherwise be obvious.