PredCorr2D(Sim.DiffProc)
PredCorr2D()所属R语言包:Sim.DiffProc
Predictor-Corrector Method For Two-Dimensional SDE
预测 - 校正法对于二维SDE
译者:生物统计家园网 机器人LoveR
描述----------Description----------
Predictor-Corrector method of simulation numerical solution of Two dimensional stochastic differential equations.
预测校正方法模拟二维随机微分方程的数值解。
用法----------Usage----------
PredCorr2D(N, T = 1, t0, x0, y0, Dt, alpha = 0.5, mu = 0.5, driftx,
drifty, diffx, diffy, Step = FALSE, Output = FALSE)
参数----------Arguments----------
参数:N
size of process.
大小的处理。
参数:T
final time.
最后的时间。
参数:t0
initial time.
初始时间。
参数:x0
initial value of the process X(t) at time t0.
初始值的过程X(t)在时间t0。
参数:y0
initial value of the process Y(t) at time t0.
初始值的过程Y(t)在时间t0。
参数:Dt
time step of the simulation (discretization).
模拟的时间步长(discretization)。
参数:alpha
weight alpha of the predictor-corrector scheme.
重量alpha的预测校正方案。
参数:mu
weight mu of the predictor-corrector scheme.
重量mu的预测校正方案。
参数:driftx
drift coefficient of process X(t): an expression of three variables t , x and y.
漂移的过程X(t)的三个变量:一个表达式t,x和y。
参数:drifty
drift coefficient of process Y(t): an expression of three variables t , x and y.
漂移的过程Y(t)的三个变量:一个表达式t,x和y。
参数:diffx
diffusion coefficient of process X(t): an expression of three variables t , x and y.
扩散系数的过程X(t)的三个变量:一个表达式t,x和y。
参数:diffy
diffusion coefficient of process Y(t): an expression of three variables t , x and y.
扩散系数的过程Y(t)的三个变量:一个表达式t,x和y。
参数:Step
if Step = TRUE ploting step by step.
如果Step = TRUE图一步一步的。
参数:Output
if output = TRUE write a output to an Excel (.csv).
如果output = TRUE写的output到Excel(CSV)。
Details
详细信息----------Details----------
the system for stochastic differential equation Two dimensional is :
系统随机微分方程二维是:
with driftx=ax(t,X(t),Y(t)), drifty=ay(t,X(t),Y(t)) and diffx=bx(t,X(t),Y(t)), diffy=by(t,X(t),Y(t)).
driftx=ax(t,X(t),Y(t)),drifty=ay(t,X(t),Y(t))和diffx=bx(t,X(t),Y(t)),diffy=by(t,X(t),Y(t))。
The method we present here just tries to approximate the states of the process first. This method is of weak convergence order 1. dW1(t) and dW2(t) are brownian motions independent.
这里介绍的方法,我们只是试图的状态的过程。这种方法的优点是弱收敛阶1。 dW1(t)和dW2(t)是独立的布朗运动。
The predictor-corrector algorithm is as follows. First consider the simple approximation (the predictor), Then choose two weighting coefficients alpha and mu in [0,1] and calculate the corrector.
预报 - 校正算法如下。首先考虑简单的近似(预测),然后选择两个权重系数alpha和mu中[0,1]和计算校正。
值----------Value----------
data.frame(time,X(t),Y(t)) and plot of process 2-D.
数据框(时间(T),X,Y(T))和积工艺2-D。
注意----------Note----------
Note that the predictor-corrector method falls back to the standard Euler method for alpha = mu = 0.
请注意,预测校正方法回落到标准的欧拉法的alpha = mu = 0。
The function by default implements the predictor corrector method with alpha = mu = 0.5.
默认情况下,该功能实现的预测校正方法alpha = mu = 0.5。
(作者)----------Author(s)----------
Boukhetala Kamal, Guidoum Arsalane.
参见----------See Also----------
diffBridge Creating Diffusion Bridge Models. snssde numerical solution of one-dimensional SDE. snssde2D numerical solution of Two-dimensional SDE. PredCorr predictor-corrector method for one-dimensional SDE.
diffBridge的创建扩散桥模型。 snssde数值解的一维的SDE。 snssde2D数值解的二维SDE。 PredCorr预报 - 校正的方法,一维的SDE。
实例----------Examples----------
## Example 1[#示例1]
driftx <- expression(cos(t*x*y))
drifty <- expression(cos(t))
diffx <- expression(0.1)
diffy <- expression(0.1)
PredCorr2D(N=5000, T = 1, t0=0, x0=0, y0=0, Dt=0.001, alpha = 0.5,
mu = 0.5, driftx, drifty, diffx, diffy, Step = FALSE,
Output = FALSE)
## ploting Step by Step[#图逐步]
PredCorr2D(N=5000, T = 1, t0=0, x0=0, y0=0, Dt=0.001, alpha = 0.5,
mu = 0.5, driftx, drifty, diffx, diffy, Step = TRUE,
Output = FALSE)
## Example 2[#示例2]
## BM 2-D[#BM的2-D]
driftx <- expression(0)
drifty <- expression(0)
diffx <- expression(1)
diffy <- expression(1)
PredCorr2D(N=5000, T = 1, t0=0, x0=0, y0=0, Dt=0.001, alpha = 0.5,
mu = 0.5, driftx, drifty, diffx, diffy, Step = FALSE,
Output = FALSE)
## ploting Step by Step[#图逐步]
PredCorr2D(N=5000, T = 1, t0=0, x0=0, y0=0, Dt=0.001, alpha = 0.5,
mu = 0.5, driftx, drifty, diffx, diffy, Step = TRUE,
Output = FALSE)
## Example 3[#示例3]
driftx <- expression(0.03*t*x-x^3)
drifty <- expression(0.03*t*y-y^3)
diffx <- expression(0.1)
diffy <- expression(0.1)
PredCorr2D(N=5000, T = 1, t0=0, x0=0, y0=0, Dt=0.001, alpha = 0.5,
mu = 0.5, driftx, drifty, diffx, diffy, Step = FALSE,
Output = FALSE)
## ploting Step by Step[#图逐步]
PredCorr2D(N=5000, T = 1, t0=0, x0=0, y0=0, Dt=0.001, alpha = 0.5,
mu = 0.5, driftx, drifty, diffx, diffy, Step = FALSE,
Output = FALSE)
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|