ito_formula function
Itô's lemma: the differential of an expression of states that follow an Itô process.
How to write it
ito_formula(f, states, drift, diffusion, time)
Gives the rule ito_differential(f) -> {dt: ..., dw: [...]}; a note says when it holds.
- f
- The expression of the states and time that is differentiated. Takes an expression.
- states
- The state variables, in brackets. Takes a list of variables, or a variable.
- drift
- The drift of each state, in brackets. Takes a list.
- diffusion
- The noise: one row for each state, one column for each driver. Takes a matrix, written as a list of rows.
- time
- The time, a variable. Takes a variable, or a list of variables.
ito_formula(f, states, drift, diffusion, time)
For one state and one driver, the call without lists; the answer is the same.
- f
- The expression of the state and time that is differentiated. Takes an expression.
- states
- The one state variable, without a list. Takes a variable, or a list of variables.
- drift
- The drift of the state. Takes an expression.
- diffusion
- The noise of the state, for one driver. Takes an expression.
- time
- The time, a variable. Takes a variable, or a list of variables.
Examples
ito_formula(x^2, [x], [mu*x], [[sigma*x]], t)In the solver,
Open in the solverito_formula(x^2, [x], [mu*x], [[sigma*x]], t)givesito_differential(x^2) -> {dt: sigma^2*x^2 + 2mu*x^2, dw: [2sigma*x^2]}.ito_formula(x*y, [x, y], [0, 0], [[s1], [s2]], t)In the solver,
Open in the solverito_formula(x*y, [x, y], [0, 0], [[s1], [s2]], t)givesito_differential(x*y) -> {dt: s1*s2, dw: [s2*x + s1*y]}.ito_formula(x^2, x, mu*x, sigma*x, t)In the solver,
Open in the solverito_formula(x^2, x, mu*x, sigma*x, t)givesito_differential(x^2) -> {dt: sigma^2*x^2 + 2mu*x^2, dw: [2sigma*x^2]}.ito_formula(ln(x), x, mu*x, sigma*x, t)In the solver,
Open in the solverito_formula(ln(x), x, mu*x, sigma*x, t)givesito_differential(ln(x)) -> {dt: mu - sigma^2/2, dw: [sigma]}.
Related functions
- ito_formula_data
The certified record behind ito_formula: its result, validity, certificate and theorem.
- ito_integral
The Itô integral of an expression of the Wiener value w and the time s, from 0 to t.
- ito_process
A process given by its drift and diffusion: dX = drift dt + diffusion dW.
- geometric_sde_path
The path of dX = mu X dt + sigma X dW, as a function of the Wiener process's value w at time t.
- geometric_brownian_motion_process
A process that grows at rate mu with relative noise sigma, started at x0.
- fit
The least-squares fit of a combination of functions through points.