I am a composer. I have 10, 30-second musical sections. The orchestra plays 5, five are played by a soloist. I would like to give them each choices. I have written the piece so that each section flows well into 2 sections that the others play.
The orchestra "mappings" are 1=>B&D 2=>C&D 3=>C&E 4=>A&B 5=>A&E. The soloist mappings are A=>2&4 B=>2&5 C=>3&4 D=>1&3 E=>1&5
Optional stipulation: The groups can play the same section twice, but must choose an unplayed section when given a choice.
I would like the piece to start with orchestra playing section 1 and end the when the soloist has played all A-E. The problem is, when I write out a flow chart, about 50% of the time there is a section that the soloist has not played after 10 back and forths. Furthermore, many ways forward never find this last section
So my question is, is there a way to change the mappings (rewrite parts of the piece), so that the soloist will get to play each of their 5 sections.
Thank you for your time.
Well, here's a graph of the situation, where the good sounding edges are included. It's a pretty graph, if you ask me. I assume this is basically what your flow chart was.
and our goal is to find paths, visiting every vertex (at least once). This is a nice visualization of the problem. There are currently exactly two valid paths:
These are the only paths that uses each section exactly once. If you want to be sure of that, notice that a cycle can't start 1-B-2, since it would then have to visit D then 3 - at which point it could go to E, but then C would be unreachable, or it could go to C-4-A, but then it would be forced to repeat. It also couldn't start 1-B-5, since then it would either go to E, and be forced to repeat thereafter, or go to A then 2 (since going to 4 would force going to B next), but then we could show that there would be no unused outgoing paths from 4, meaning it would have to end there, which is a problem since if exactly 10 sections were used, it would end with the soloist. This suffices to show that it wouldn't be able to start 1-B without repeat. Similarly, it can't start 1-D-3-C, as that would mean when the orchestra played section 2, it would have to repeat. This suffices to show any such path must start 1-D-3-E-5-A and there are only two paths from there.
There are most certainly more paths when you relax your conditions as you have, and if you think about why certain paths are failing, you can try to move edges about to help it out a little; perhaps avoiding the cycles between two sections would increase the number of good orders to play the music in. This is certainly something you have to play around with more than something you can solve rigorously though, but if you just try to figure out where things go wrong for a lot of paths, you can figure out what you need to change to solve those issues and at least create more paths through the graph.
You could also start with two sets of five points, and start drawing paths of length $10$ through them, alternating between the two sets (soloist & orchestra) - which would possible orders to play the piece - and continually add new such paths until you had every node of the graph with exactly $2$ outgoing edges. If you do this well, it should yield a graph with more potential paths through it - but given that you've already written the piece, I would imagine that entirely changing the structure of the piece is not a great option.