Optimal Dynamic Control of a Useful Class of Randomly Jumping Processes