The discovery (or invention) of negatives, which happened several centuries ago by the Chinese, Indians and Arabs, has of course be of fundamental importance to mathematics. From then on, it seems that mathematicians have always striven to "put the negatives" into whatever algebraic structure they came across, in analogy with the usual "numerical" structure, $\mathbb{Z}$.

But perhaps there are cases in which the notion of a semiring seems more natural than the notion of a ring (I will be very very sloppy!):

1) The Cardinals. They have a natural structure of semiring, and the usual construction that allows to pass from $\mathbb{N}$ to $\mathbb{Z}$ cannot be performed in this case without great loss of information.

2) Vector bundles over a space; and notice that in the infinite rank case the Grothendieck *ring* is trivial just because negatives are allowed.

3) Tropical geometry.

4) The notion of semiring, as opposed to that of a ring, seems to be the most natural for "categorification", in two separate senses: (i) For example, the set of isomorphism classes of objects in a category with direct sums and tensor products (e.g. finitely-generated projective modules over a commutative ring) is naturally a semiring. When one constructs the Grothendieck ring of a category, one usually adds formal negatives, but this can be a very lossy operation, as in the case of vector bundles. (ii) A category with finite biproducts (products and coproducts, and a natural isomorphism between these) is automatically enriched over commutative monoids, but not automatically enriched over abelian groups. As such, it's naturally a "many object semiring", but not a "many object ring".

Do you have any examples of contexts in which semirings (which are not rings) arise naturally in mathematics?

cardinalshad commutative addition, given by disjoint union of sets. In particular, for infinite cardinals, addition is just "max", at least if we have axiom of choice (so that any two cardinals are comparable). The noncommutative addition, I thought, was forordinals, which are (isomorphism classes of) sets along with well-orderings. The ordered disjoint union is definitely noncommutative. $\endgroup$ – Theo Johnson-Freyd Apr 7 '10 at 15:56