Work locally where the needed derivatives of the level set can be represented by the implicit function theorem. Differentiating while holding the indicated coordinate fixed gives
Multiplying the three implicit differentiation formulas proves
This cyclic partial derivative identity is asserted where all three finite coordinate derivatives exist, in particular when . It is not a globally defined product at points where one of the necessary coordinate parametrizations is singular.
At a fixed point, the first equation gives . Substitution into the second gives , so the equilibrium points are . The Jacobian matrix is
At the origin its eigenvalues are , so the origin is an unstable spiral. The local rotation is clockwise: on the positive -axis the velocity points downward. At either nonzero equilibrium point,
Thus both nonzero equilibria are saddles, with eigenvalues . The stable manifold is tangent to , and the unstable manifold to , at each saddle equilibrium. Since all these equilibrium points are hyperbolic, linear stability of a planar equilibrium gives their actual local types.
For the phase portrait, the nullclines are and , the latter defined away from . The horizontal direction has the sign of ; the vertical direction has the sign of . The system is invariant under , so trajectories occur in centrally symmetric pairs. The arrows below show these directions; the highlighted stable manifolds enter the saddle equilibria, whereas the highlighted unstable manifolds leave them.
Figure 1.
Clockwise unstable spiral and two saddles with stable and unstable separatrices
. Details.
Combine the real variables into . The linear system of ordinary differential equations becomes , hence for arbitrary real . Taking real and imaginary parts gives
The two independent constants cover every real initial condition. In the phase plane, the distance from the origin grows as and the polar angle changes at rate . For the trajectories are outward logarithmic spirals; for they are outward straight rays.
Construct independent copies of , also independent of , and define the random sum , taking the empty sum to be zero. Independence gives, conditional on ,
The law of total expectation gives the transform composition for an independent random sum
The summands are nonnegative, so this equality is valid also as an extended-valued expectation. Where the right-hand side is finite, it is the ordinary moment-generating function of the constructed random sum. The construction does not assert a finite moment-generating function near zero for arbitrary : heavy tails can prevent this. For example a nonnegative with no positive exponential moments and already shows the necessary qualification.
The moment-generating function is for real where this expectation is finite; a finite neighborhood of zero is usually required when speaking of an existing moment-generating function. For a standard normal distribution, completing the square gives
The translated Gaussian density integrates to one, so
For a nonnegative integer-valued random variable, the probability generating function is
initially for , with . For the Poisson distribution, insert its probability mass function and sum the exponential series:
Thus
Factor the right-hand side as . Its equilibrium points are , and gives
Indeed , and . The phase line has downward motion for , upward motion for , downward motion for , and upward motion for . The uniqueness of a smooth autonomous differential equation prevents trajectories from crossing an equilibrium point. Consequently trajectories starting between and approach zero as , while those outside that interval move away from the three equilibrium points. The constant trajectories and representative nonconstant trajectories are shown below.
Figure 1.
Representative trajectories and equilibrium levels for the scalar cubic differential equation
. Details.
An equilibrium of an autonomous differential equation is a constant with . Put . For differentiable , the linear stability analysis gives
Thus the linear perturbation is proportional to . More directly, continuity of makes point toward on both sides when , and away from it when . Hence
The sign refers to evolution toward increasing . If , linear stability analysis is inconclusive: the leading nonzero nonlinear term or the signs of on either side are needed. For example is attracting whereas is repelling, despite the same zero linear coefficient.
Eliminate the free constant by comparing consecutive values:
Therefore an appropriate inhomogeneous linear recurrence is
Its homogeneous part has solution , and is a particular solution. A first-order linear recurrence relation has one arbitrary initial value, so this gives exactly the desired general solution.
Substitution of into the linear recurrence relation gives . Since , division by proves the sequence is a solution exactly when .
For a nonzero triple root of a polynomial , the repeated characteristic root of a linear recurrence rule gives the three independent solutions . One way to see the polynomial factors is to write : the recurrence becomes the third forward difference operator applied to equal to zero, so is a quadratic polynomial. Thus
These three constants give arbitrary initial values , hence the full third-order solution. If , the recurrence instead reduces to : the first three values are arbitrary and every subsequent value is zero. The nonzero-root formula must not be used to discard those initial values.
Normalization of the probability density function gives
The first two moments are
Consequently
The cumulative distribution function is on . For with the uniform distribution on , inverse transform sampling therefore uses
The inverse lies in the required interval and satisfies .
Now the event is to hit before , starting at . Up to the first of those two hitting times, translate the interval by one unit; its endpoints become and the starting point becomes . The gambler's ruin hitting probability is therefore
Stopping at is essential: using the original absorbing endpoint would answer a different event.
The initial position is . Applying the gambler's ruin hitting probability and mean hitting time gives
For comparison, the original central starting position would give probability and mean time minutes.
The homogeneous linear recurrence relation has characteristic polynomial , hence general solution . For the expected-time recurrence, rearrangement gives , for which is a particular solution. Thus
Imposing the absorbing boundary conditions from the preceding parts gives the gambler's ruin formulas
Let be the expected remaining hitting time of either endpoint, measured in minutes. The first step consumes one minute, after which first-step analysis gives
The expectation is finite: from any interior state, a block of twenty leftward steps guarantees absorption and has probability . Thus the survival probability over successive twenty-step blocks has a geometric upper bound. This justifies using finite expectations in the recurrence.

There are unlisted articles, also show them or only show them.