  We introduce a class of continuous planar processes, called "semimartingales
on rays", and develop for them a change-of-variable formula involving quite
general classes of test functions. Special cases of such planar processes are
diffusions which choose, once they reach the origin, the rays for their
subsequent voyage according to a fixed probability measure in the manner of
Walsh (1978). We develop existence and uniqueness results up to an explosion
time for these "Walsh diffusions", study their asymptotic behavior, and develop
tests for explosions in finite time. We use these results to find an optimal
strategy, in a problem of control with discretionary stopping involving Walsh
diffusions.
