A filter comprises porous material that traps contaminants when fluid passes through under an applied pressure difference. One side-effect of this applied pressure, however, is that it compresses the filter. This changes the permeability, which may affect its performance. As the applied pressure increases the flux of fluid processed by the filter will also increase but the permeability will decrease. Eventually the permeability reaches zero at a point in the filter and the fluid flux falls to zero. In this paper we derive a model for the fluid transport through a filter due to an applied pressure difference and the resulting compression. We use this to determine the maximum operating flux that can be achieved without the permeability reaching zero and the filter shutting down. We determine the material properties that balance the desire to maximize flux while minimizing power use. We also show how choosing an initial spatially dependent permeability can lead to a uniformly permeable filter under operation and we find the permeability distribution that maximizes the flux for a given applied pressure, both of which have desirable industrial implications. The ideas laid out in this paper set a framework for modelling more complex scenarios such as filter blocking.