Integration.Steps {fptdApprox} | R Documentation |
Subintervals and Integration Steps To Approximate First-Passage-Time Densities
Description
According to the First-Passage-Time Location (FPTL) function and the arguments in the function call, this function calculates suitable subintervals and integration steps in order to approximate the first-passage-time (f.p.t.) density.
Usage
Integration.Steps(sfptl, variableStep = TRUE, from.t0 = FALSE,
to.T = FALSE, n = 250, p = 0.2, alpha = 1)
Arguments
sfptl |
an object of class “summary.fptl”. |
variableStep |
a logical value indicating whether a variable integration step is used. |
from.t0 |
a logical value indicating whether the approximation should be calculated from the lower end of the
interval considered, |
to.T |
a logical value indicating whether the approximation should be calculated to the upper end of the
interval considered, |
n |
Number of points used to determine the integration step in subintervals |
p |
Ratio of n used to determine the integration step in subintervals |
alpha |
Parameter used to determine the integration step in subintervals
|
Details
Based on the information provided by the FPTL function contained in the sfptl
object, this function computes and returns
suitable subintervals and integration steps in order to approximate the density
function of the f.p.t. variable according to the other arguments in the function call.
When the sfptl
object is of length greater than 1, it comes from an unconditioned f.p.t. problem. Each component is associated with
the same f.p.t. problem conditioned on different values of the initial distribution
(equally spaced in the range of the distribution). Let ,
, these values. For each initial value
let
,
and
,
,
the interesting time instants provided by the FPTL function and stored in the
instants
component of the j-th list in the sfptl
object.
Then, the time instants , where
provide a suitable partition of interval to approximate the f.p.t density
for the fixed value
of the initial distribution.
If the sfptl
object is of length 1, it comes from a conditioned f.p.t. problem. In this case we denote the interesting time
instants provided by the FPTL function and stored in the sfptl
object by ,
and
.
In what follows, is the integer part of
.
For each list in the sfptl
object the function computes
where
and
If variableStep = TRUE
, for and
, also computes
-
where
with
If
, we then set
equal to
and
is recalculated.
-
where
with
when the
sfptl
object is of length 1 andfrom.t0 = TRUE
, or thesfptl
object is of length greater than 1.If
, we then set
equal to
and
is recalculated.
-
where
with
when the
sfptl
object is of length 1 andto.T = TRUE
, or thesfptl
object is of length greater than 1.If
, we then set
equal to
and
is recalculated.
and
are recommended; otherwise, some integration steps can be excessively large.
If the sfptl
object is of length 1 (conditioned f.p.t. problem), the suitable subintervals and integration steps that the function provides are:
If
variableStep = TRUE
,-
in subintervals
,
.
-
in subintervals
,
. In these subintervals is possible to avoid applying the numerical algorithm to approximate the f.p.t. density provided that the value of the approximate density at the time instant
is almost 0.
-
in subinterval
, if
from.t0 = TRUE
. -
in subinterval
, if
to.T = TRUE
.
-
If
variableStep = FALSE
the function computesThen
If
from.t0 = FALSE
andto.T = FALSE
,is readjusted to exactly split the interval
.
If
from.t0 = TRUE
andto.T = FALSE
,is readjusted to exactly split the interval
.
If
from.t0 = FALSE
andto.T = TRUE
,is readjusted to exactly split the interval
.
If
from.t0 = TRUE
andto.T = TRUE
,is readjusted to exactly split the interval
.
is a suitable fixed integration step in subintervals
,
, and
,
; in subintervals
if
from.t0 = TRUE
, and inif
to.T = TRUE
. The endpoints of such subintervals are readjusted according to this integration step.
If the sfptl
object is a list of length greater than 1 (unconditioned f.p.t problem), a common partition of
the interval is calculated from the suitable partitions of this interval for each
fixed value of the initial distribution.
Let, in unified form, ,
, the suitable integration steps
(calculated for each
in similar manner to the case of the
sfptl
object is of length 1) in
subintervals , with
and
,
.
Then, the ordered values of all time instants in the suitable partitions,
, provide a common suitable partition of the interval
in subintervals
,
,
where
and
.
For this partition, the function computes
-
-
, if
from.t0 = TRUE
. -
, if
to.T = TRUE
.
Thus,
If
variableStep = TRUE
, the suitable subintervals and integrations steps that the function provides are-
in subintervals
,
.
-
in subinterval
, if
from.t0 = TRUE
. -
in subinterval
, if
to.T = TRUE
.
Each integration step is readjusted to exactly split the corresponding subinterval.
-
If
variableStep = FALSE
, a suitable fixed integration step for any subintervalis
In this case it is not possible to avoid applying the approximation algorithm in
.
Then
If
from.t0 = FALSE
andto.T = FALSE
,is readjusted to exactly split the interval
.
If
from.t0 = TRUE
andto.T = FALSE
,is readjusted to exactly split the interval
.
If
from.t0 = FALSE
andto.T = TRUE
,is readjusted to exactly split the interval
.
If
from.t0 = TRUE
andto.T = TRUE
,is readjusted to exactly split the interval
.
is a suitable fixed integration step in subintervals
,
, in subintervals
if
from.t0 = TRUE
, and inif
to.T = TRUE
. The endpoints of such subintervals are readjusted according to this integration step.
Value
A two-component list:
H |
A matrix of subintervals and integrations steps that we must consider in order to approximate the f.p.t.
density according to the information contained in the |
skip |
A list of logical vectors indicating, for each subinterval, the values of the initial distribution for which we must check whether it is possible to avoid applying the numerical algorithm. |
Author(s)
Patricia Román-Román, Juan J. Serrano-Pérez and Francisco Torres-Ruiz.
References
Román, P., Serrano, J. J., Torres, F. (2008) First-passage-time location function: Application to determine first-passage-time densities in diffusion processes. Comput. Stat. Data Anal., 52, 4132–4146.
P. Román-Román, J.J. Serrano-Pérez, F. Torres-Ruiz. (2012) An R package for an efficient approximation of first-passage-time densities for diffusion processes based on the FPTL function. Applied Mathematics and Computation, 218, 8408–8428.
P. Román-Román, J.J. Serrano-Pérez, F. Torres-Ruiz. (2014) More general problems on first-passage times for diffusion processes: A new version of the fptdApprox R package. Applied Mathematics and Computation, 244, 432–446.
See Also
Approx.fpt.density
to approximate f.p.t. densities from objects of class “summary.fptl” and create objects of class “fpt.density”.
summary.fptl
to locate the f.p.t. variable and create objects of class “summary.fptl” from objects of class
“fptl”.
FPTL
to evaluate the FPTL function and create objects of class “fptl”.
Examples
## Continuing the summary.fptl(.) example:
Integration.Steps(yy)
Integration.Steps(yy, from.t0 = TRUE)
Integration.Steps(yy, to.T = TRUE, n = 100, p = 0.25)
Integration.Steps(zz)