digraph test { rankdir=LR node [shape=circle] root [label="", shape=point] root -> r [label=⅓] root -> f [label=⅔] r [label=r] r -> rr [label=⅓] rr [label=r] rr -> rrr [label=⅓] rrr [label=r] rrr -> rrrr [label=⅓] rrrr [label=r] rr -> rrf [label=⅔] rrf [label=f] rrf -> rrfr [label=⅓] rrfr [label=r] rrf -> rrff [label=⅔] rrff [label=f] rrr -> rrrf [label=⅔] rrrf [label=f] r -> rf [label=⅔] rf [label=f] rf -> rfr [label=⅓] rfr [label=r] rfr -> rfrr [label=⅓] rfrr [label=r] rfr -> rfrf [label=⅔] rfrf [label=f] rf -> rff [label=⅔] rff [label=f] rff -> rffr [label=⅓] rffr [label=r] rff -> rfff [label=⅔] rfff [label=f] f [label=f] f -> fr [label=⅓] fr [label=r] fr -> frr [label=⅓] frr [label=r] frr -> frrr [label=⅓] frrr [label=r] frr -> frrf [label=⅔] frrf [label=f] fr -> frf [label=⅔] frf [label=f] frf -> frfr [label=⅓] frfr [label=r] frf -> frff [label=⅔] frff [label=f] f -> ff [label=⅔] ff [label=f] ff -> ffr [label=⅓] ffr [label=r] ffr -> ffrr [label=⅓] ffrr [label=r] ffr -> ffrf [label=⅔] ffrf [label=f] ff -> fff [label=⅔] fff [label=f] fff -> fffr [label=⅓] fffr [label=r] fff -> ffff [label=⅔] ffff [label=f] }