Text this: Optimal Control of Membrane Processes in the Presence of Fouling