A Theoretical Study of Bipolar Porous Electrodes