# Use TransformedProcess to Create a Custom Process

Define compensated Poisson process.

 In[1]:= Xpoisson\[ScriptCapitalP] = PoissonProcess[\[Lambda]]; \[ScriptCapitalP]1 = TransformedProcess[p[t] - Mean[poisson\[ScriptCapitalP][t]], p \[Distributed] poisson\[ScriptCapitalP], t];

Simulate the process with unit rate for 30 seconds.

 In[2]:= Xdata1 = RandomFunction[\[ScriptCapitalP]1 /. \[Lambda] -> 1, {0, 30, 0.1}, 3];
 In[3]:= XListLinePlot[data1]
 Out[3]=

Compute the covariance function for the process.

 In[4]:= XCovarianceFunction[\[ScriptCapitalP]1, s, t]
 Out[4]=

Define a Bessel process in two dimensions.

 In[5]:= X\[ScriptCapitalP]2 = TransformedProcess[Sqrt[ x[t]^2 + y[t]^2], {x \[Distributed] WienerProcess[], y \[Distributed] WienerProcess[]}, t];

Simulate the process for 10 seconds.

 In[6]:= Xdata2 = RandomFunction[\[ScriptCapitalP]2, {0, 10, 0.01}, 3];
 In[7]:= XListLinePlot[data2, PlotRange -> All]
 Out[7]=

Compute the mean and variance functions for the process.

 In[8]:= X{Mean[\[ScriptCapitalP]2[t]], Variance[\[ScriptCapitalP]2[t]]}
 Out[8]=

## Mathematica

Questions? Comments? Contact a Wolfram expert »