Solving the pellet problem for multicomponent mass transport and complex reactions