I am working on a project related to an emergency evacuation:
Find the minimum time to make $n$ people to evacuate the city (travel time of the slowest). There is 1 vehicle that can contain $p$ people and travel at the speed of the slowest person of the group. One person has to bring back the vehicle used for transportation.
This problem is a generalization to the bridge crossing / torch problem.
I found solution for $p \leq 2$ which comes down to sort the people by travel time and to iterate pairwise whether it is better for the pair of people to travel together using 2 runners or to travel separately using 1 runner.
I tried to adapt it for $p=3$ but things escalated quickly and I ended up with many strategies to compare for every group of 3 persons with 1, 2, 3 runners and could not find a way to generalize for $p \geq 3$.
I would check out the paper The capacity-$C$ torch problem (behind a paywall) and this similar (same?) paper The Capacity-$C$ Torch Problem Full Version (including all proofs) (pdf) by Backhouse and Truong. Since the answer to your question is the subject of these research papers, it'd be tough to synthesize their algorithms into a response here, so I won't, but they appear to contain an algorithm that solves the question you are seeking to answer.