Changed 'rate' function to make it faster.

All the changes are behind the scene. It does not change the way this
function works.
bad_pores should be trimmed at the very end of the function so that 'pname_transform' is calculated correctly.
Merge branch 'develop' into feature/sim_layer

Conflicts:
	OpenPNM/Network/__MatFile__.py