Add tests for sim and make them pass

Fixed a bizarre bug in sim.simple_expose and sim.expose where if
the production rate p is a call to production.P_tot and we do not
assign p(z) to a temporary variable then increasing the depth z
actually increases resulting concentrations. There is a note in the
code now explaining the reason for the temporary, and test cases
that will catch things like this should they ever crop up again.