Optimization of a stagewise biochemical reactor system with product feedback